Changeset 84 for trunk/src/reglookup.c


Ignore:
Timestamp:
01/19/07 09:52:25 (17 years ago)
Author:
tim
Message:

rearranged structure contents to reduce fragmentation on 64 bit systems.

make regfi interface return const structures to help enforce separation

removed a little cruft from some parsing functions

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/reglookup.c

    r83 r84  
    524524
    525525
    526 void printValue(REGF_VK_REC* vk, char* prefix)
     526void printValue(const REGF_VK_REC* vk, char* prefix)
    527527{
    528528  char* quoted_value = NULL;
     
    534534
    535535  /* Thanks Microsoft for making this process so straight-forward!!! */
     536  /* XXX: this logic should be abstracted  and pushed into the regfi
     537   *      interface.  This includes the size limits.
     538   */
    536539  size = (vk->data_size & ~VK_DATA_IN_OFFSET);
    537540  if(vk->data_size & VK_DATA_IN_OFFSET)
     
    618621void printValueList(REGFI_ITERATOR* i, char* prefix)
    619622{
    620   REGF_VK_REC* value;
     623  const REGF_VK_REC* value;
    621624
    622625  value = regfi_iterator_first_value(i);
     
    630633
    631634
    632 void printKey(REGF_NK_REC* k, char* full_path)
     635void printKey(const REGF_NK_REC* k, char* full_path)
    633636{
    634637  static char empty_str[1] = "";
     
    679682void printKeyTree(REGFI_ITERATOR* iter)
    680683{
    681   REGF_NK_REC* root = NULL;
    682   REGF_NK_REC* cur = NULL;
    683   REGF_NK_REC* sub = NULL;
     684  const REGF_NK_REC* root = NULL;
     685  const REGF_NK_REC* cur = NULL;
     686  const REGF_NK_REC* sub = NULL;
    684687  char* path = NULL;
    685688  int key_type = regfi_type_str2val("KEY");
     
    750753int retrievePath(REGFI_ITERATOR* iter, char** path)
    751754{
    752   REGF_VK_REC* value;
     755  const REGF_VK_REC* value;
    753756  char* tmp_path_joined;
    754757  const char** tmp_path;
Note: See TracChangeset for help on using the changeset viewer.