]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Completed StoreIOState constructor, changed some flags to bool type
authorFrancesco Chemolli <kinkie@squid-cache.org>
Sun, 20 Jan 2013 21:25:52 +0000 (22:25 +0100)
committerFrancesco Chemolli <kinkie@squid-cache.org>
Sun, 20 Jan 2013 21:25:52 +0000 (22:25 +0100)
src/StoreIOState.cc
src/StoreIOState.h
src/store_io.cc

index a56e803feed649676bc9c805efd64242979b7f3e..ee159cc1db26b7751a034848dddcd50607a756c2 100644 (file)
@@ -46,9 +46,13 @@ StoreIOState::operator new (size_t amount)
 void
 StoreIOState::operator delete (void *address) {assert (0);}
 
-StoreIOState::StoreIOState()
+StoreIOState::StoreIOState() :
+        swap_dirn(-1), swap_filen(-1), e(NULL), mode(O_BINARY),
+        offset_(0), file_callback(NULL), callback(NULL), callback_data(NULL)
 {
-    mode = O_BINARY;
+    read.callback = NULL;
+    read.callback_data = NULL;
+    flags.closing = false;
 }
 
 off_t
index 6f0f6d2676d28f37aff9c4361e17269656ac326a..d794798e64013bb3deae5643f6231eadec06b39c 100644 (file)
@@ -105,7 +105,7 @@ public:
     } read;
 
     struct {
-        unsigned int closing:1;        /* debugging aid */
+        bool closing;  /* debugging aid */
     } flags;
 };
 
index 403a050a56eaef0fdff25741d68fe42492a2fae0..e2f9d2a2c37def1b4b8257fd4d6d43604caa84ef 100644 (file)
@@ -63,7 +63,7 @@ storeClose(StoreIOState::Pointer sio, int how)
         return;
     }
 
-    sio->flags.closing = 1;
+    sio->flags.closing = true;
 
     debugs(20,3,HERE << "storeClose: calling sio->close(" << how << ")");
     sio->close(how);