- Timestamp:
- 03/02/10 19:08:42 (15 years ago)
- Location:
- trunk/src
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/common.c
r160 r168 160 160 char* tmp_ptr; 161 161 char* delim; 162 uint32 ret_val_left, i, tmp_len;162 uint32_t ret_val_left, i, tmp_len; 163 163 164 164 if(data == NULL || data->size == 0) -
trunk/src/reglookup-recover.c
r161 r168 40 40 41 41 42 char* getQuotedData(int fd, uint32 offset, uint32length)43 { 44 uint8 * buf;42 char* getQuotedData(int fd, uint32_t offset, uint32_t length) 43 { 44 uint8_t* buf; 45 45 char* quoted_buf; 46 uint32 len;46 uint32_t len; 47 47 48 48 if((lseek(fd, offset, SEEK_SET)) == -1) 49 49 return NULL; 50 50 51 buf = (uint8 *)malloc(length);51 buf = (uint8_t*)malloc(length); 52 52 if(buf == NULL) 53 53 return NULL; … … 75 75 char* quoted_raw = ""; 76 76 77 *tmp_time = nt_time_to_unix(&nk->mtime);77 *tmp_time = regfi_nt2unix_time(&nk->mtime); 78 78 tmp_time_s = gmtime(tmp_time); 79 79 strftime(mtime, sizeof(mtime), "%Y-%m-%d %H:%M:%S", tmp_time_s); … … 217 217 218 218 219 int printCell(REGFI_FILE* f, uint32 offset)219 int printCell(REGFI_FILE* f, uint32_t offset) 220 220 { 221 221 char* quoted_buf; 222 uint32 cell_length;222 uint32_t cell_length; 223 223 bool unalloc; 224 224 … … 249 249 REGFI_NK_REC* cur_ancestor; 250 250 char* ret_val; 251 uint32 virt_offset, i, stack_size, ret_val_size, ret_val_used, offset;252 int32 max_size;251 uint32_t virt_offset, i, stack_size, ret_val_size, ret_val_used, offset; 252 int32_t max_size; 253 253 REGFI_BUFFER* path_element; 254 254 … … 278 278 path_element = talloc(path_stack, REGFI_BUFFER); 279 279 if(path_element != NULL) 280 path_element->buf = (uint8 *)quote_string(cur_ancestor->keyname,280 path_element->buf = (uint8_t*)quote_string(cur_ancestor->keyname, 281 281 key_special_chars); 282 282 … … 343 343 344 344 345 bool removeRange(range_list* rl, uint32 offset, uint32length)346 { 347 int32 rm_idx;345 bool removeRange(range_list* rl, uint32_t offset, uint32_t length) 346 { 347 int32_t rm_idx; 348 348 const range_list_element* cur_elem; 349 349 … … 405 405 const range_list_element* cur_elem; 406 406 REGFI_VK_REC* vk; 407 uint32 i, j;407 uint32_t i, j; 408 408 409 409 for(i=0; i < range_list_size(unalloc_cells); i++) … … 450 450 range_list* bd_cells; 451 451 REGFI_BUFFER data; 452 uint32 i, j, offset, cell_length, length;453 int32 max_size;452 uint32_t i, j, offset, cell_length, length; 453 int32_t max_size; 454 454 bool unalloc; 455 455 … … 583 583 const range_list_element* cur_elem; 584 584 REGFI_NK_REC* key; 585 uint32 i, j;585 uint32_t i, j; 586 586 int error_code = 0; 587 587 … … 637 637 REGFI_VK_REC* vk; 638 638 const range_list_element* cur_elem; 639 uint32 i, j, num_keys, off, values_length;640 int32 max_size;639 uint32_t i, j, num_keys, off, values_length; 640 int32_t max_size; 641 641 642 642 num_keys=range_list_size(unalloc_keys); … … 663 663 * parsed structure. 664 664 */ 665 values_length = (nk->values->num_values+1)*sizeof(uint32 );665 values_length = (nk->values->num_values+1)*sizeof(uint32_t); 666 666 if(values_length != (values_length & 0xFFFFFFF8)) 667 667 values_length = (values_length & 0xFFFFFFF8) + 8; … … 727 727 const range_list_element* cur_elem; 728 728 REGFI_SK_REC* sk; 729 uint32 i, j;729 uint32_t i, j; 730 730 731 731 for(i=0; i < range_list_size(unalloc_cells); i++) … … 778 778 REGFI_NK_REC* tmp_key; 779 779 REGFI_VK_REC* tmp_value; 780 uint32 argi, arge, i, j, ret, num_unalloc_keys;780 uint32_t argi, arge, i, j, ret, num_unalloc_keys; 781 781 782 782 /* Process command line arguments */ -
trunk/src/reglookup.c
r162 r168 132 132 char* next = NULL; 133 133 char* copy; 134 uint32 ret_cur = 0;134 uint32_t ret_cur = 0; 135 135 136 136 ret_val = (char**)malloc((REGFI_MAX_DEPTH+1+1)*sizeof(char**)); … … 179 179 void freePath(char** path) 180 180 { 181 uint32 i;181 uint32_t i; 182 182 183 183 if(path == NULL) … … 196 196 const REGFI_ITER_POSITION* cur; 197 197 const REGFI_NK_REC* tmp_key; 198 uint32 buf_left = 127;199 uint32 buf_len = buf_left+1;200 uint32 name_len = 0;201 uint32 grow_amt;198 uint32_t buf_left = 127; 199 uint32_t buf_len = buf_left+1; 200 uint32_t name_len = 0; 201 uint32_t grow_amt; 202 202 char* buf; 203 203 char* new_buf; … … 245 245 if(name_len+1 > buf_left) 246 246 { 247 grow_amt = (uint32 )(buf_len/2);247 grow_amt = (uint32_t)(buf_len/2); 248 248 buf_len += name_len+1+grow_amt-buf_left; 249 249 if((new_buf = realloc(buf, buf_len)) == NULL) … … 298 298 REGFI_CLASSNAME* classname; 299 299 300 *tmp_time = nt_time_to_unix(&k->mtime);300 *tmp_time = regfi_nt2unix_time(&k->mtime); 301 301 tmp_time_s = gmtime(tmp_time); 302 302 strftime(mtime, sizeof(mtime), "%Y-%m-%d %H:%M:%S", tmp_time_s); … … 454 454 char* tmp_path_joined; 455 455 const char** tmp_path; 456 uint32 i;456 uint32_t i; 457 457 458 458 if(path == NULL) … … 557 557 REGFI_ITERATOR* iter; 558 558 int retr_path_ret; 559 uint32 argi, arge;559 uint32_t argi, arge; 560 560 561 561 /* Process command line arguments */
Note: See TracChangeset
for help on using the changeset viewer.