]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Fix segmentation fault. Still need to fix wrong resolution of constraints in distribu...
authorMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Wed, 4 Dec 2013 06:57:07 +0000 (06:57 +0000)
committerMartin Kronbichler <kronbichler@lnm.mw.tum.de>
Wed, 4 Dec 2013 06:57:07 +0000 (06:57 +0000)
git-svn-id: https://svn.dealii.org/trunk@31869 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/include/deal.II/lac/constraint_matrix.templates.h

index 20a85f4c66b78d7f36f5296d4d4f0310c7de1f38..c4762246d84e5216481f737174d19a095ac0dfc1 100644 (file)
@@ -2431,7 +2431,8 @@ ConstraintMatrix::distribute_local_to_global (
                                          local_matrix, col_ptr, val_ptr);
           const size_type n_values = col_ptr - &cols[0];
           if (n_values > 0)
-            global_matrix.add(row, n_values, &cols[0], &vals[0], false, true);
+            global_matrix.add(row, n_values, &cols[0], val_ptr-n_values, false,
+                              true);
         }
       else
         internals::resolve_matrix_row (global_rows, i, 0, n_actual_dofs,
@@ -2524,7 +2525,8 @@ ConstraintMatrix::distribute_local_to_global (
                                      local_matrix, col_ptr, val_ptr);
       const size_type n_values = col_ptr - &cols[0];
       if (n_values > 0)
-        global_matrix.add(row, n_values, &cols[0], &vals[0], false, true);
+        global_matrix.add(row, n_values, &cols[0], val_ptr-n_values,
+                          false, true);
     }
 
   my_scratch_data.in_use = false;
@@ -2628,7 +2630,8 @@ distribute_local_to_global (const FullMatrix<double>     &local_matrix,
                   const size_type n_values = col_ptr - &cols[0];
                   if (n_values > 0)
                     global_matrix.block(block, block_col).add(row, n_values,
-                                                              &cols[0], &vals[0],
+                                                              &cols[0],
+                                                              val_ptr-n_values,
                                                               false, true);
                 }
               else

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.