- Timestamp:
- Apr 21, 2009, 10:04:41 AM (16 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
source/ariba/utility/misc/sha1.cpp
r2994 r2995 242 242 } 243 243 244 bool ret = true; 245 size_t rets = -1; 246 244 247 for(i = 0; i < ulBlocks; i++) { 245 fread(uData, 1, SHA1_MAX_FILE_BUFFER, fIn); 248 rets = fread(uData, 1, SHA1_MAX_FILE_BUFFER, fIn); 249 ret &= (rets > 0 ); 246 250 Update((UINT_8 *)uData, SHA1_MAX_FILE_BUFFER); 247 251 } 248 252 249 253 if(ulRest != 0) { 250 fread(uData, 1, ulRest, fIn); 254 rets = fread(uData, 1, ulRest, fIn); 255 ret &= (rets > 0 ); 251 256 Update((UINT_8 *)uData, ulRest); 252 257 } … … 254 259 fclose(fIn); 255 260 fIn = NULL; 256 return true;261 return ret; 257 262 } 258 263 #endif
Note:
See TracChangeset
for help on using the changeset viewer.