Ignore:
Timestamp:
02/08/10 07:29:41 (2 years ago)
Author:
lowjoel
Message:

Updated to trunk r1764

Location:
branches/eraser6/CodeReview
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/eraser6/CodeReview

  • branches/eraser6/CodeReview/Eraser.DefaultPlugins/ErasureMethods/FirstLast16KB.cs

    r1768 r1769  
    8686            if (paths == null) 
    8787            { 
    88                 if (targetSize <= dataSize) 
     88                if (targetSize <= DataSize) 
    8989                    amountToWrite = targetSize; 
    9090                else 
    91                     amountToWrite = dataSize * 2; 
     91                    amountToWrite = DataSize * 2; 
    9292            } 
    9393            else 
    94                 amountToWrite = paths.Count * dataSize * 2; 
     94                amountToWrite = paths.Count * DataSize * 2; 
    9595 
    9696            //The final amount has to be multiplied by the number of passes. 
     
    116116            //If the target stream is shorter than or equal to 32kb, just forward it to 
    117117            //the default function. 
    118             if (strm.Length < dataSize * 2) 
     118            if (strm.Length < DataSize * 2) 
    119119            { 
    120120                method.Erase(strm, erasureLength, prng, callback); 
     
    124124            //We need to intercept the callback function as we run the erasure method 
    125125            //twice on two parts of the file. 
     126            long dataSize = method.CalculateEraseDataSize(null, DataSize * 2); 
    126127            ErasureMethodProgressFunction customCallback = 
    127128                delegate(long lastWritten, long totalData, int currentPass) 
    128129                { 
    129                     callback(lastWritten, dataSize * 2, currentPass); 
     130                    callback(lastWritten, dataSize, currentPass); 
    130131                }; 
    131132 
     
    142143        /// The amount of data to be erased from the header and the end of the file. 
    143144        /// </summary> 
    144         private const long dataSize = 16 * 1024; 
     145        private const long DataSize = 16 * 1024; 
    145146 
    146147        private ErasureMethod method; 
Note: See TracChangeset for help on using the changeset viewer.