]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
mds: init atid in context
authorSage Weil <sage@inktank.com>
Sat, 29 Sep 2012 08:29:49 +0000 (01:29 -0700)
committerSage Weil <sage@inktank.com>
Sat, 29 Sep 2012 08:29:49 +0000 (01:29 -0700)
CID 717236: Uninitialized scalar field (UNINIT_CTOR)
At (2): Non-static class member "atid" is not initialized in this constructor nor in any functions that it calls.

Signed-off-by: Sage Weil <sage@inktank.com>
src/mds/MDCache.cc

index 3662a37dc23b67bfc5ef1c383bcb8864cd48a69a..7a5c0f5407db628a21ef6c6a8d9c8fbea15a742d 100644 (file)
@@ -7602,7 +7602,7 @@ class C_MDC_AnchorPrepared : public Context {
   bool add;
 public:
   version_t atid;
-  C_MDC_AnchorPrepared(MDCache *c, CInode *i, bool a) : cache(c), in(i), add(a) {}
+  C_MDC_AnchorPrepared(MDCache *c, CInode *i, bool a) : cache(c), in(i), add(a), atid(0) {}
   void finish(int r) {
     cache->_anchor_prepared(in, atid, add);
   }