diff src/ls-hdf5.h @ 11584:cda4aa780d58

Another round of initialising members in the constructor initialisation list
author Pascal Dupuis <Pascal.Dupuis@uclouvain.be>
date Thu, 20 Jan 2011 17:07:26 -0500
parents fd0a3ac60b0e
children 12df7854fa7c
line wrap: on
line diff
--- a/src/ls-hdf5.h
+++ b/src/ls-hdf5.h
@@ -43,11 +43,12 @@
   // keep track of current item index in the file
   int current_item;
 
-  hdf5_fstreambase () { file_id = -1; }
+  hdf5_fstreambase () : file_id (-1), current_item () { }
 
   ~hdf5_fstreambase () { close (); }
 
   hdf5_fstreambase (const char *name, int mode, int /* prot */ = 0)
+    : file_id (-1), current_item (-1)
     {
       if (mode & std::ios::in)
         file_id = H5Fopen (name, H5F_ACC_RDONLY, H5P_DEFAULT);