diff --git a/include/shred.h b/include/shred.h index 0937766..a89457e 100644 --- a/include/shred.h +++ b/include/shred.h @@ -17,12 +17,12 @@ #include #include -#define CHUNK_SIZE 1024*1024*2 //amount of bytes that are overwritten at once +#define CHUNK_SIZE 1024*1024*2 //amount of bytes that are overwritten at once --> 2MB #define CHUNK_DIMENSION 100U //amount of chunks are read at once from random source //#define DEMO_DRIVE_SIZE 1024*1024*256L // 256MB //#define DEMO_DRIVE_SIZE 1024*1024*1024L // 1GB -#define DEMO_DRIVE_SIZE 1024*1024*1024*10L // 10GB +//#define DEMO_DRIVE_SIZE 1024*1024*1024*10L // 10GB typedef int fileDescriptor; diff --git a/src/shred.cpp b/src/shred.cpp index 3e70e44..8eee2d2 100644 --- a/src/shred.cpp +++ b/src/shred.cpp @@ -109,17 +109,6 @@ int Shred::shredDrive(Drive* drive, int* ipSignalFd) #ifdef LOG_LEVEL_HIGH Logger::logThis()->info("Shred-Task: Read new random data - Drive: " + drive->getSerial()); #endif -/* - int retFDataSync = fdatasync(driveFileDiscr); - if(retFDataSync != 0) - { - std::string errorMsg(strerror(retFDataSync)); - Logger::logThis()->error("Shred-Task: Flush drive failed! " + errorMsg + " - Drive: " + drive->getSerial()); - perror("unable to flush random data"); - cleanup(); - return -1; - } -*/ } @@ -169,17 +158,6 @@ int Shred::shredDrive(Drive* drive, int* ipSignalFd) return -1; } }//end one chunk write - /* - int retFDataSync = fdatasync(driveFileDiscr); - if(retFDataSync != 0) - { - std::string errorMsg(strerror(retFDataSync)); - Logger::logThis()->error("Shred-Task: Flush drive failed! " + errorMsg + " - Drive: " + drive->getSerial()); - perror("unable to flush random data"); - cleanup(); - return -1; - } - */ if(0 != iRewindDrive(driveFileDiscr)) { cleanup();