]> git.sesse.net Git - freerainbowtables/blobdiff - Client Applications/converti2/converti2.cpp
merged paths
[freerainbowtables] / Client Applications / converti2 / converti2.cpp
index 3ad8c09a75fb0dbc6e3dfe4c873621f3fa2b8ba2..1d8d5e79619444325b3bea2cda1c423df42190a3 100644 (file)
@@ -327,17 +327,19 @@ void ConvertRainbowTable(string sPathName, string sResultFileName, unsigned int
                                unsigned int nChains = nAllocatedSize / sizeof(RainbowChain);
                                uint64 curPrefix = 0, prefixStart = 0;
                                vector<IndexRow> indexes;
-                               while(reader->GetChainsLeft() > 0) {
+                               unsigned int chainsLeft;
+                               while((chainsLeft = reader->GetChainsLeft()) > 0) {
                                        
 /*                                     if (ftell(file) == nFileLen)
                                                break;*/
+                                       printf("%u chains left to read\n", chainsLeft);
                                        int nReadThisRound;
                                        clock_t t1 = clock();
                                        printf("reading...\n");
 #ifdef _MEMORYDEBUG
                        printf("Grabbing %i chains from file\n", nChains);
 #endif
-                       reader->ReadChains(nChains, pChain);
+                                       reader->ReadChains(nChains, pChain);
 #ifdef _MEMORYDEBUG
                        printf("Recieved %i chains from file\n", nChains);
 #endif
@@ -445,7 +447,7 @@ void ConvertRainbowTable(string sPathName, string sResultFileName, unsigned int
 
                                                // then write the distance amount of 00's
                                                if(diffSize > 1000) {
-                                                       printf("WARNING! The distance to the next prefix is %i. Do you want to continue writing %i bytes of 0x00? Press y to continue", diffSize, diffSize);
+                                                       printf("WARNING! The distance to the next prefix is %i. Do you want to continue writing %i bytes of 0x00? Press y to continue", diffSize, (diffSize*m_indexrowsizebytes));
                                                        #ifdef _WIN32
                                                        if ( _getch() != 'y' ) {
                                                        #else