Changeset 2241 in MondoRescue for branches/2.2.9/mondo/src/lib/mr_mem.c


Ignore:
Timestamp:
Jun 29, 2009, 7:19:14 PM (15 years ago)
Author:
Bruno Cornec
Message:

r3144@localhost: bruno | 2009-06-26 12:18:08 +0200

  • Remove mr_string.c|.h useless and in de=uplication with mr_str.c|.h
  • Solve with valgrind's help some memroy leak (harmless mostly)
  • Solve a seg fault at end, when unallocating a bkpinfo member after the strcuture disallocation !
  • after mr_strtok, memory ssociated with the token needs to be free
  • Adds a new function free_newt_stuff to free newt related allocated memory
  • Do not exit if mr_free is unsuccessful, and only warn when debug > 8
File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/2.2.9/mondo/src/lib/mr_mem.c

    r1196 r2241  
    2525 * *allocated variable points then to the original content
    2626 * pointed to by the caller
     27 * In case of NULL pointer it just logs it
    2728 */
    2829void mr_free_int(void **allocated, int line, const char *file) {
     
    3536        *allocated = NULL;
    3637    } else {
    37         mr_msg_int(1,line,file,"Attempt to reference NULL pointer\nExiting...");
    38         mr_exit(-1,"Attempt to reference NULL pointer");
     38        mr_msg_int(8,line,file,"Attempt to free NULL pointer");
    3939    }
    4040}
Note: See TracChangeset for help on using the changeset viewer.