Changeset 115 in MondoRescue for trunk/mondo/mondo/mondorestore


Ignore:
Timestamp:
Nov 6, 2005, 3:18:38 PM (18 years ago)
Author:
andree
Message:

free variable after it has been used in call to log_to_screen() rather
than before. Fixes segmentation fault in mondorestore.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/mondo/mondo/mondorestore/mondo-prep.c

    r89 r115  
    18111811    } else {
    18121812        /* MBR needs an extended partition if more than 4 partitions */
    1813         if (strcmp(part_table_fmt,"MBR") == 0) {
     1813        if (strcmp(part_table_fmt, "MBR") == 0) {
    18141814            if (partno == 5) {
    18151815                if (prev_partno >= 4) {
    1816                     log_to_screen("You need to leave at least one partition free, for 'extended/logical'");
     1816                    log_to_screen
     1817                        ("You need to leave at least one partition free, for 'extended/logical'");
    18171818                    paranoid_free(program);
    18181819                    paranoid_free(partition_name);
     
    18221823                    return (1);
    18231824                } else {
    1824                     sprintf(output + strlen(output), "n\ne\n%d\n\n\n", prev_partno + 1);
     1825                    sprintf(output + strlen(output), "n\ne\n%d\n\n\n",
     1826                            prev_partno + 1);
    18251827                }
    18261828            }
     
    25902592    final_size = get_phys_size_of_drive(drive_name);
    25912593    sprintf(tmp, "final_size = %ld MB", final_size);
     2594    log_to_screen(tmp);
    25922595    paranoid_free(tmp);
    2593     log_to_screen(tmp);
    25942596}
    25952597
Note: See TracChangeset for help on using the changeset viewer.