Ignore:
Timestamp:
Jan 3, 2014, 5:44:13 PM (10 years ago)
Author:
Bruno Cornec
Message:

which_partition_format now returns a dynamically allocated string which is then used consistently across the project

File:
1 edited

Legend:

Unmodified
Added
Removed
  • branches/3.2/mondo/src/common/libmondo-mountlist.c

    r3236 r3237  
    6767
    6868    /*@ pointers ******************************************************* */
    69     char *part_table_fmt;
     69    char *part_table_fmt = NULL;
    7070
    7171    /*@ initialize ***************************************************** */
     
    195195            part_table_fmt = which_partition_format(drive);
    196196            /* no spare primary partitions to help accommodate the logical(s)? */
    197             if ((curr_part_no >= 5 && prev_part_no == 4)
    198                 && (strcmp(part_table_fmt, "MBR") == 0)) {
     197            if ((curr_part_no >= 5 && prev_part_no == 4) && (strcmp(part_table_fmt, "MBR") == 0)) {
    199198                mr_asprintf(tmp, " Partition %ss4 is occupied.", drive);
    200199                log_it(tmp);
     
    203202                res++;
    204203            }
     204            mr_free(part_table_fmt);
     205
    205206            /* does partition /dev/adXsY exist more than once in the mountlist? */
    206207            for (i = 0, device_copies = 0;
Note: See TracChangeset for help on using the changeset viewer.