]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Initialize some variables.
authorDavid Wells <wellsd2@rpi.edu>
Sat, 27 Jan 2018 18:23:12 +0000 (13:23 -0500)
committerDavid Wells <wellsd2@rpi.edu>
Sat, 27 Jan 2018 19:33:27 +0000 (14:33 -0500)
This was found by cppcheck.

include/deal.II/base/time_stepping.templates.h
include/deal.II/meshworker/output.h
source/base/data_out_base.cc

index bb29c7bdd29c9445a43bd56bc3ea30378f7c8952..2021a04c5643030edff1147d236572b308502d66 100644 (file)
@@ -421,7 +421,8 @@ namespace TimeStepping
     refine_tol(refine_tol),
     coarsen_tol(coarsen_tol),
     last_same_as_first(false),
-    last_stage(nullptr)
+    last_stage(nullptr),
+    status {}
   {
     // virtual functions called in constructors and destructors never use the
     // override in a derived class
index 4d6f01ffe3e7038d7cc931e4a2dda6917190209b..5e50d06ddd3b883bc6f544c90a51859040c8b8e8 100644 (file)
@@ -159,6 +159,8 @@ namespace MeshWorker
     inline
     GnuplotPatch::GnuplotPatch()
       :
+      n_vectors(numbers::invalid_unsigned_int),
+      n_points(numbers::invalid_unsigned_int),
       os(nullptr)
     {}
 
index 829fb0b1981accdfb24cfb22a85b02fb42c11e59..d69de3b30bfec389da34931cf9f5be26f80dc626 100644 (file)
@@ -6974,7 +6974,7 @@ void DataOutBase::write_hdf5_parallel (const std::vector<Patch<dim,spacedim> > &
               ExcMessage("DataOutBase was asked to write HDF5 output for a space dimension of 1. "
                          "HDF5 only supports datasets that live in 2 or 3 dimensions."));
 
-  int ierr;
+  int ierr = 0;
   (void)ierr;
 #ifndef DEAL_II_WITH_HDF5
   // throw an exception, but first make sure the compiler does not warn about

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.