Changeset 1087 in MondoRescue for branches/stable/mondo/src/common/libmondo-tools.c
- Timestamp:
- Feb 2, 2007, 11:31:00 PM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/stable/mondo/src/common/libmondo-tools.c
r1080 r1087 11 11 #include "my-stuff.h" 12 12 #include "mr_mem.h" 13 #include "mr_file.h" 13 14 #include "mondostructures.h" 14 15 #include "lib-common-externs.h" … … 409 410 char *iso_tmp; 410 411 char *iso_path; 412 FILE *fd1 = NULL; 411 413 412 414 assert(bkpinfo != NULL); … … 643 645 bkpinfo->isodir); 644 646 log_it("command = %s", command); 645 log_it("res of it = %s",646 call_program_and_get_last_line_of_output(command));647 647 sprintf(iso_dev, "%s", 648 648 call_program_and_get_last_line_of_output(command)); 649 sprintf(tmp, "%s/ISO-DEV", bkpinfo->tmpdir);650 write_one_liner_data_file(tmp, 651 call_program_and_get_last_line_of_output652 (command));649 log_it("res of it = %s", iso_dev); 650 651 fd1 = mr_fopen(MONDORESTORECFG, "a"); 652 mr_fprintf(fd1, "iso-dev %s\n", iso_dev); 653 653 654 654 sprintf(command, "mount | grep -w %s | tail -n1 | cut -d' ' -f3", 655 655 iso_dev); 656 656 log_it("command = %s", command); 657 log_it("res of it = %s",658 call_program_and_get_last_line_of_output(command));659 657 sprintf(iso_mnt, "%s", 660 658 call_program_and_get_last_line_of_output(command)); 661 sprintf(tmp, "%s/ISO-MNT", bkpinfo->tmpdir); 662 write_one_liner_data_file(tmp, 663 call_program_and_get_last_line_of_output 664 (command)); 659 660 log_it("res of it = %s", iso_mnt); 661 mr_fprintf(fd1, "iso-mnt %s\n", iso_mnt); 665 662 log_it("isomnt: %s, %d", iso_mnt, strlen(iso_mnt)); 663 666 664 sprintf(iso_tmp, "%s", bkpinfo->isodir); 667 665 if (strlen(iso_tmp) < strlen(iso_mnt)) { … … 670 668 sprintf(iso_path, "%s", iso_tmp + strlen(iso_mnt)); 671 669 } 672 sprintf(tmp, "%s/ISODIR", bkpinfo->tmpdir);673 write_one_liner_data_file(tmp, iso_path);674 670 log_it("isodir: %s", iso_path); 675 sprintf(tmp, "%s/ISO-PREFIX", bkpinfo->tmpdir);676 write_one_liner_data_file(tmp, bkpinfo->prefix); 671 mr_fprintf(fd1, "isodir %s\n", iso_path); 672 677 673 log_it("iso-prefix: %s", bkpinfo->prefix); 678 679 /* End patch */ 674 mr_fprintf(fd1, "iso-prefix %s\n", bkpinfo->prefix); 675 676 mr_flcose(fd1); 680 677 } // end of iso code 681 678
Note:
See TracChangeset
for help on using the changeset viewer.