Fix the initialization of members in Class 20/123320/1
authorSungjun, Lee <sjun221.lee@samsung.com>
Wed, 5 Apr 2017 07:45:55 +0000 (16:45 +0900)
committerSungjun, Lee <sjun221.lee@samsung.com>
Wed, 5 Apr 2017 07:45:55 +0000 (16:45 +0900)
Change-Id: I900a1ad7348fbf8f62c26c77fd74b62200013141
Signed-off-by: Sungjun, Lee <sjun221.lee@samsung.com>
server/block-device.cpp
server/engine/encryption/dmcrypt-engine.cpp
server/engine/encryption/ecryptfs-engine.cpp
server/engine/encryption/ext4-engine.cpp
server/engine/erase/mmc-engine.cpp
server/key-manager/luks.h

index 184ef88..89d3e20 100644 (file)
@@ -23,7 +23,7 @@
 
 namespace ode {
 
-BlockDevice::BlockDevice(const std::string &path) : name("")
+BlockDevice::BlockDevice(const std::string &path) : name(""), blockSize(0)
 {
        int ret = 0;
        runtime::File file(path);
index 30b88fc..9086669 100644 (file)
@@ -231,7 +231,7 @@ void copyInPlace(const std::string &source, const std::string &destination,
 } // namepsace
 
 DMCryptEngine::DMCryptEngine(const std::string &src, const std::string &dest, const ProgressBar &prgsBar) :
-       source(src), destination(dest), progress(prgsBar)
+       source(src), destination(dest), progress(prgsBar), mounted(false)
 {
 }
 
index b4a1c03..539f055 100644 (file)
@@ -314,7 +314,7 @@ void ecryptfsUmount(const std::string &destination)
 } // namespace
 
 EcryptfsEngine::EcryptfsEngine(const std::string &src, const std::string &dest, const ProgressBar &prg) :
-       source(src), destination(dest), progress(prg)
+       source(src), destination(dest), progress(prg), mounted(false)
 {
 }
 
index 351266a..d0a0cb2 100644 (file)
@@ -289,7 +289,7 @@ void copyInPlace(const std::string& source, const std::string& destination,
 } // namespace
 
 Ext4Engine::Ext4Engine(const std::string& src, const std::string& dest, const ProgressBar &prgsBar) :
-       source(src), destination(dest), progress(prgsBar)
+       source(src), destination(dest), progress(prgsBar), mounted(false)
 {
 }
 
index f9d84c6..3d8fd45 100644 (file)
@@ -61,7 +61,7 @@ int getTotalFileCount(const std::string &path)
 } /* namespace */
 
 MMCEraseEngine::MMCEraseEngine(const ProgressBar &prgsBar) :
-       progressBar(prgsBar)
+       progressBar(prgsBar), totalFileCount(0), erasedFileCount(0)
 {
 }
 
index 74ef9ce..c790f4b 100644 (file)
@@ -43,7 +43,7 @@ struct LUKSHeader final {
        char padding[256];
 
        LUKSHeader() :
-               magic{'L', 'U', 'K', 'S', 0xba, 0xbe}, version(1)
+               magic{'L', 'U', 'K', 'S', 0xba, 0xbe}, version(1), payloadOffset(0), keyBytes(0), mkDigestIteration(0)
        {
                for (auto &key : keyslot) {
                        unsigned char *buf = (unsigned char*)&key.active;