]> https://gitweb.dealii.org/ - dealii.git/commitdiff
initialize some pointers to NULL.
authorDavid Wells <wellsd2@rpi.edu>
Tue, 3 Jan 2017 17:06:44 +0000 (12:06 -0500)
committerDavid Wells <wellsd2@rpi.edu>
Wed, 4 Jan 2017 00:54:48 +0000 (19:54 -0500)
This was caught by cppcheck.

include/deal.II/lac/solver_cg.h
include/deal.II/lac/solver_richardson.h

index 574ded4a2963065a096850f6f38241cb31a683c4..e64e31e569df1258165c8819b91153606cacdfdf 100644 (file)
@@ -337,6 +337,9 @@ SolverCG<VectorType>::SolverCG (SolverControl        &cn,
                                 const AdditionalData &data)
   :
   Solver<VectorType>(cn),
+  Vr(NULL),
+  Vp(NULL),
+  Vz(NULL),
   additional_data(data)
 {}
 
index 20f07b2bd2a565ad789ca76c70e24d845dc290b9..ae13849174f4b578f2ff98cc7a15580888ae39dd 100644 (file)
@@ -193,6 +193,8 @@ SolverRichardson<VectorType>::SolverRichardson(SolverControl            &cn,
                                                const AdditionalData     &data)
   :
   Solver<VectorType> (cn,mem),
+  Vr(NULL),
+  Vd(NULL),
   additional_data(data)
 {}
 
@@ -203,6 +205,8 @@ SolverRichardson<VectorType>::SolverRichardson(SolverControl        &cn,
                                                const AdditionalData &data)
   :
   Solver<VectorType> (cn),
+  Vr(NULL),
+  Vd(NULL),
   additional_data(data)
 {}
 

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.