Changeset 3610 in MondoRescue for branches/3.2/mondo/src/mondorestore/mondo-prep.c
- Timestamp:
- Nov 5, 2016, 6:12:23 PM (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.2/mondo/src/mondorestore/mondo-prep.c
r3570 r3610 154 154 char *tmp; 155 155 char *tmp1 = NULL; 156 char *tmp2 = NULL; 156 157 char *incoming; 157 158 char *command; … … 186 187 #endif 187 188 188 if (strstr(call_program_and_get_last_line_of_output("cat /proc/cmdline"), "nolvm")) { 189 tmp = call_program_and_get_last_line_of_output("cat "CMDLINE); 190 if (strstr(tmp, "nolvm")) { 191 mr_free(tmp); 189 192 return(0); 190 193 } 194 mr_free(tmp); 195 191 196 if (!(fin = fopen("/tmp/i-want-my-lvm", "r"))) { 192 197 log_OS_error("/tmp/i-want-my-lvm"); … … 299 304 if (lvmversion == 2) { 300 305 mr_asprintf(tmp1, "tail -n5 %s | grep Insufficient | tail -n1", MONDO_LOGFILE); 301 strcpy(tmp, call_program_and_get_last_line_of_output(tmp1));302 free(tmp1);303 306 } else { 304 307 mr_asprintf(tmp1, "tail -n5 %s | grep lvcreate | tail -n1", MONDO_LOGFILE); 305 strcpy(tmp, call_program_and_get_last_line_of_output(tmp1));306 free(tmp1);307 308 } 309 tmp2 = call_program_and_get_last_line_of_output(tmp1); 310 strcpy(tmp, tmp2); 311 mr_free(tmp2); 312 mr_free(tmp1); 313 308 314 for (p = tmp; *p != '\0' && !isdigit(*p); p++); 309 315 extents = atol(p); … … 1482 1488 // mark relevant partition as bootable 1483 1489 mr_asprintf(tmp1,"mr-make-me-bootable /tmp/mountlist.txt %s",drivename); 1484 call_program_and_get_last_line_of_output(tmp1);1490 tmp = call_program_and_get_last_line_of_output(tmp1); 1485 1491 mr_free(tmp1); 1492 mr_free(tmp); 1486 1493 1487 1494 log_msg(0,"------------------- end of fdisk.log... ------------------");
Note:
See TracChangeset
for help on using the changeset viewer.