Changeset 1107 in MondoRescue for branches/stable/mondo/src/common/libmondo-devices.c
- Timestamp:
- Feb 8, 2007, 12:09:34 AM (17 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/stable/mondo/src/common/libmondo-devices.c
r1080 r1107 108 108 strcpy(tmp, where_is_root_mounted()); 109 109 sprintf(comment, "root is mounted at %s\n", tmp); 110 log_msg(0, comment);111 log_msg(0,110 mr_msg(0, comment); 111 mr_msg(0, 112 112 "No, Schlomo, that doesn't mean %s is the root partition. It's just a debugging message. Relax. It's part of am_I_in_disaster_recovery_mode().", 113 113 tmp); … … 141 141 mr_free(tmp); 142 142 mr_free(comment); 143 log_msg(1, "Is this a ramdisk? result = %d", is_this_a_ramdisk);143 mr_msg(1, "Is this a ramdisk? result = %d", is_this_a_ramdisk); 144 144 return (is_this_a_ramdisk); 145 145 } … … 226 226 #endif 227 227 228 log_msg(3, "Ejecting %s", dev);228 mr_msg(3, "Ejecting %s", dev); 229 229 res2 = run_program_and_log_output(command, 1); 230 230 mr_free(command); … … 483 483 } 484 484 if (res) { 485 log_msg(1, "mount failed");486 } else { 487 log_msg(1, "mount succeeded with %s", dev);485 mr_msg(1, "mount failed"); 486 } else { 487 mr_msg(1, "mount succeeded with %s", dev); 488 488 } 489 489 mr_free(dev); … … 521 521 if (g_cdrw_drive_is_here[0]) { 522 522 strcpy(cdrw_device, g_cdrw_drive_is_here); 523 log_msg(3, "Been there, done that. Returning %s", cdrw_device);523 mr_msg(3, "Been there, done that. Returning %s", cdrw_device); 524 524 mr_free(comment); 525 525 mr_free(tmp); … … 529 529 } 530 530 if (g_backup_media_type == dvd) { 531 log_msg(1,531 mr_msg(1, 532 532 "This is dumb. You're calling find_cdrw_device() but you're backing up to DVD. WTF?"); 533 533 mr_free(comment); … … 621 621 if (g_cdrom_drive_is_here[0] && !isdigit(g_cdrom_drive_is_here[0])) { 622 622 strcpy(output, g_cdrom_drive_is_here); 623 log_msg(3, "Been there, done that. Returning %s", output);623 mr_msg(3, "Been there, done that. Returning %s", output); 624 624 retval = 0; 625 625 goto end_of_find_cdrom_device; … … 627 627 if (the_last_place_i_found_it[0] != '\0' && !try_to_mount) { 628 628 strcpy(output, the_last_place_i_found_it); 629 log_msg(3,629 mr_msg(3, 630 630 "find_cdrom_device() --- returning last found location - '%s'", 631 631 output); … … 645 645 if (!find_home_of_exe(cdr_exe)) { 646 646 strcpy(output, "/dev/cdrom"); 647 log_msg(4, "Can't find cdrecord; assuming %s", output);647 mr_msg(4, "Can't find cdrecord; assuming %s", output); 648 648 if (!does_device_exist(output)) { 649 log_msg(4, "That didn't work. Sorry.");649 mr_msg(4, "That didn't work. Sorry."); 650 650 retval = 1; 651 651 goto end_of_find_cdrom_device; … … 659 659 fin = popen(command, "r"); 660 660 if (!fin) { 661 log_msg(4, "command=%s", command);661 mr_msg(4, "command=%s", command); 662 662 log_OS_error("Cannot popen command"); 663 663 return (1); … … 690 690 #ifndef __FreeBSD__ 691 691 if (strlen(phrase_two) == 0) { 692 log_msg(4, "Not running phase two. String is empty.");692 mr_msg(4, "Not running phase two. String is empty."); 693 693 } else { 694 694 sprintf(command, "dmesg | grep \"%s\" 2> /dev/null", phrase_two); 695 695 fin = popen(command, "r"); 696 696 if (!fin) { 697 log_msg(4, "Cannot run 2nd command - non-fatal, fortunately");697 mr_msg(4, "Cannot run 2nd command - non-fatal, fortunately"); 698 698 } else { 699 699 for (fgets(tmp, MAX_STR_LEN, fin); !feof(fin); 700 700 fgets(tmp, MAX_STR_LEN, fin)) { 701 log_msg(5, "--> '%s'", tmp);701 mr_msg(5, "--> '%s'", tmp); 702 702 if (tmp[0] != ' ' && tmp[1] != ' ') { 703 703 p = strchr(tmp, ':'); … … 706 706 if (strstr(tmp, "DVD")) { 707 707 sprintf(dvd_last_resort, "/dev/%s", tmp); 708 log_msg(4,708 mr_msg(4, 709 709 "Ignoring '%s' because it's a DVD drive", 710 710 tmp); … … 723 723 #ifdef __FreeBSD__ 724 724 if (!found_it) { 725 log_msg(4, "OK, approach 2");725 mr_msg(4, "OK, approach 2"); 726 726 if (!(found_it = set_dev_to_this_if_rx_OK(output, "/dev/cdrom"))) { 727 727 if (! … … 759 759 #else 760 760 if (!found_it && strlen(dvd_last_resort) > 0) { 761 log_msg(4, "Well, I'll use the DVD - %s - as a last resort",761 mr_msg(4, "Well, I'll use the DVD - %s - as a last resort", 762 762 dvd_last_resort); 763 763 strcpy(output, dvd_last_resort); … … 768 768 strrchr(output, '/') + 1); 769 769 if (system(tmp) == 0) { 770 log_msg(4,770 mr_msg(4, 771 771 "%s is not right. It's being SCSI-emulated. Continuing.", 772 772 output); … … 777 777 778 778 if (found_it) { 779 log_msg(4, "(find_cdrom_device) --> '%s'", output);779 mr_msg(4, "(find_cdrom_device) --> '%s'", output); 780 780 if (!does_device_exist(output)) { 781 781 found_it = FALSE; 782 log_msg(4, "OK, I was wrong, I haven't found it... yet.");782 mr_msg(4, "OK, I was wrong, I haven't found it... yet."); 783 783 } 784 784 } 785 785 786 786 if (!found_it) { 787 log_msg(4, "OK, approach 2");787 mr_msg(4, "OK, approach 2"); 788 788 if (!(found_it = set_dev_to_this_if_rx_OK(output, "/dev/scd0"))) { 789 789 if (!(found_it = set_dev_to_this_if_rx_OK(output, "/dev/sr0"))) { … … 828 828 if (found_it && try_to_mount) { 829 829 if (mount_CDROM_here(output, mountpoint)) { 830 log_msg(4, "[Cardigans] I've changed my mind");830 mr_msg(4, "[Cardigans] I've changed my mind"); 831 831 found_it = FALSE; 832 832 } else { 833 833 sprintf(tmp, "%s/archives", mountpoint); 834 834 if (!does_file_exist(tmp)) { 835 log_msg(4, "[Cardigans] I'll take it back");835 mr_msg(4, "[Cardigans] I'll take it back"); 836 836 found_it = FALSE; 837 837 } else { 838 838 sprintf(command, "umount %s", output); 839 839 paranoid_system(command); 840 log_msg(4, "I'm confident the Mondo CD is in %s", output);840 mr_msg(4, "I'm confident the Mondo CD is in %s", output); 841 841 } 842 842 } … … 846 846 if (found_it) { 847 847 if (!does_file_exist(output)) { 848 log_msg(3, "I still haven't found it.");848 mr_msg(3, "I still haven't found it."); 849 849 return (1); 850 850 } 851 log_msg(3, "(find_cdrom_device) --> '%s'", output);851 mr_msg(3, "(find_cdrom_device) --> '%s'", output); 852 852 strcpy(the_last_place_i_found_it, output); 853 853 strcpy(g_cdrom_drive_is_here, output); … … 859 859 "%s -scanbus | grep \"[0-9],[0-9],[0-9]\" | grep \"[D|C][V|D]\" | grep -n \"\" | grep \"%s\" | cut -d':' -f2", 860 860 cdr_exe, g_cdrw_drive_is_here); 861 log_msg(1, "command=%s", command);861 mr_msg(1, "command=%s", command); 862 862 strcpy(tmp, call_program_and_get_last_line_of_output(command)); 863 863 if (tmp[0]) { 864 864 strcpy(output, tmp); 865 log_msg(4, "Finally found it at %s", output);865 mr_msg(4, "Finally found it at %s", output); 866 866 retval = 0; 867 867 goto end_of_find_cdrom_device; 868 868 } else { 869 log_msg(4, "Still couldn't find it.");869 mr_msg(4, "Still couldn't find it."); 870 870 retval = 1; 871 871 goto end_of_find_cdrom_device; … … 897 897 if (g_dvd_drive_is_here[0]) { 898 898 strcpy(output, g_dvd_drive_is_here); 899 log_msg(3, "Been there, done that. Returning %s", output);899 mr_msg(3, "Been there, done that. Returning %s", output); 900 900 return (0); 901 901 } … … 904 904 ("dvdrecord -scanbus 2> /dev/null | grep \") '\" | grep -n \"\" | grep DVD | cut -d':' -f1") 905 905 ); 906 log_msg(5, "tmp = '%s'", tmp);906 mr_msg(5, "tmp = '%s'", tmp); 907 907 if (!tmp[0]) 908 908 sprintf(tmp, call_program_and_get_last_line_of_output … … 916 916 sprintf(output, "/dev/scd%d", devno); 917 917 strcpy(g_dvd_drive_is_here, output); 918 log_msg(2, "I think DVD is at %s", output);919 } else { 920 log_msg(2, "I cannot find DVD");918 mr_msg(2, "I think DVD is at %s", output); 919 } else { 920 mr_msg(2, "I cannot find DVD"); 921 921 retval = 1; 922 922 } 923 923 924 924 if (try_to_mount) { 925 log_msg(1, "Ignoring the fact that try_to_mount==TRUE");925 mr_msg(1, "Ignoring the fact that try_to_mount==TRUE"); 926 926 } 927 927 return (retval); … … 988 988 989 989 if (outvalB <= 0) { 990 log_msg(1, "Error getting size of %s: %s", drive, strerror(errno));990 mr_msg(1, "Error getting size of %s: %s", drive, strerror(errno)); 991 991 #if linux 992 992 fileid = open(drive, O_RDONLY); … … 997 997 cylindersize = hdgeo.heads * hdgeo.sectors / 2; 998 998 outvalA = cylindersize * cylinders / 1024; 999 log_msg(2, "Got Harddisk geometry, C:%d, H:%d, S:%d",999 mr_msg(2, "Got Harddisk geometry, C:%d, H:%d, S:%d", 1000 1000 hdgeo.cylinders, hdgeo.heads, hdgeo.sectors); 1001 1001 gotgeo = 1; 1002 1002 } else { 1003 log_msg(1, "Harddisk geometry wrong");1003 mr_msg(1, "Harddisk geometry wrong"); 1004 1004 } 1005 1005 } else { 1006 log_msg(1,1006 mr_msg(1, 1007 1007 "Error in ioctl() getting new hard disk geometry (%s), resizing in unsafe mode", 1008 1008 strerror(errno)); … … 1010 1010 close(fileid); 1011 1011 } else { 1012 log_msg(1, "Failed to open %s for reading: %s", drive,1012 mr_msg(1, "Failed to open %s for reading: %s", drive, 1013 1013 strerror(errno)); 1014 1014 } 1015 1015 if (!gotgeo) { 1016 log_msg(1, "Failed to get harddisk geometry, using old mode");1016 mr_msg(1, "Failed to get harddisk geometry, using old mode"); 1017 1017 } 1018 1018 /* … … 1020 1020 if (ioctl (fd, HDIO_GETGEO, &hdgeo) != -1) { 1021 1021 close (fd); 1022 log_msg (2, "Geometry of drive %s is C:%d, H:%d, S%d, its size is %d MB", drive, hdgeo.cylinders, hdgeo.heads, hdgeo.sectors, (hdgeo.cylinders * hdgeo.heads * hdgeo.sectors / 2 / 1024));1022 mr_msg (2, "Geometry of drive %s is C:%d, H:%d, S%d, its size is %d MB", drive, hdgeo.cylinders, hdgeo.heads, hdgeo.sectors, (hdgeo.cylinders * hdgeo.heads * hdgeo.sectors / 2 / 1024)); 1023 1023 if ( hdgeo.cylinders && hdgeo.heads && hdgeo.sectors ) { 1024 1024 outvalB = ((long) (hdgeo.cylinders * hdgeo.heads * hdgeo.sectors / 2 / 1024)); … … 1034 1034 outvalC = (outvalA > outvalB) ? outvalA : outvalB; 1035 1035 1036 // log_msg (5, "drive = %s, error = %s", drive, strerror (errno));1036 // mr_msg (5, "drive = %s, error = %s", drive, strerror (errno)); 1037 1037 // fatal_error ("GPSOD: Unable to get size of drive"); 1038 log_msg(1, "%s --> %ld or %ld --> %ld", drive, outvalA, outvalB,1038 mr_msg(1, "%s --> %ld or %ld --> %ld", drive, outvalA, outvalB, 1039 1039 outvalC); 1040 1040 … … 1077 1077 close(fd); 1078 1078 } 1079 log_msg(4, "drive = %s, error = %s", drive, strerror(errno));1079 mr_msg(4, "drive = %s, error = %s", drive, strerror(errno)); 1080 1080 fatal_error("GPSOD: Unable to get size of drive"); 1081 1081 #else … … 1087 1087 if (ioctl(fd, HDIO_GETGEO, &hdgeo) != -1) { 1088 1088 close(fd); 1089 log_msg(2,1089 mr_msg(2, 1090 1090 "Geometry of drive %s is C:%d, H:%d, S%d, its size is %d MB", 1091 1091 drive, hdgeo.cylinders, hdgeo.heads, hdgeo.sectors, … … 1161 1161 } 1162 1162 if (!(p = strstr(tmp, "GB")) && !(p = strstr(tmp, "MB"))) { 1163 log_msg(3, "Cannot find %s's size: dmesg isn't helping either.",1163 mr_msg(3, "Cannot find %s's size: dmesg isn't helping either.", 1164 1164 drive); 1165 1165 mr_free(tmp); … … 1280 1280 // assert_string_is_neither_NULL_nor_zerolength(device_raw); 1281 1281 if (device_raw[0] != '/' && !strstr(device_raw, ":/")) { 1282 log_msg(1, "%s needs to have a '/' prefixed - I'll do it",1282 mr_msg(1, "%s needs to have a '/' prefixed - I'll do it", 1283 1283 device_raw); 1284 1284 sprintf(tmp, "/%s", device_raw); … … 1286 1286 strcpy(tmp, device_raw); 1287 1287 } 1288 log_msg(1, "Is %s mounted?", tmp);1288 mr_msg(1, "Is %s mounted?", tmp); 1289 1289 if (!strcmp(tmp, "/proc") || !strcmp(tmp, "proc")) { 1290 log_msg(1,1290 mr_msg(1, 1291 1291 "I don't know how the heck /proc made it into the mountlist. I'll ignore it."); 1292 1292 return (0); … … 1312 1312 sprintf(tmp, "%s | grep -E \"^%s\" > /dev/null 2> /dev/null", 1313 1313 SWAPLIST_COMMAND, device_with_space); 1314 log_msg(4, "tmp (command) = '%s'", tmp);1314 mr_msg(4, "tmp (command) = '%s'", tmp); 1315 1315 if (!system(tmp)) { 1316 1316 retval = 1; … … 1434 1434 1435 1435 } 1436 log_msg(4, "(mount_CDROM_here --- device=%s, mountpoint=%s", device,1436 mr_msg(4, "(mount_CDROM_here --- device=%s, mountpoint=%s", device, 1437 1437 mountpoint); 1438 1438 /*@ end vars *************************************************** */ … … 1447 1447 #endif 1448 1448 1449 log_msg(4, command);1449 mr_msg(4, command); 1450 1450 if (strncmp(device, "/dev/", 5) == 0) { 1451 1451 retract_CD_tray_and_defeat_autorun(); 1452 1452 } 1453 1453 retval = system(command); 1454 log_msg(1, "system(%s) returned %d", command, retval);1454 mr_msg(1, "system(%s) returned %d", command, retval); 1455 1455 1456 1456 mr_free(command); … … 1491 1491 assert(cd_number_i_want > 0); 1492 1492 1493 // log_msg(3, "Insisting on CD number %d", cd_number_i_want);1493 // mr_msg(3, "Insisting on CD number %d", cd_number_i_want); 1494 1494 1495 1495 if (IS_THIS_A_STREAMING_BACKUP(bkpinfo->backup_media_type)) { 1496 log_msg(3,1496 mr_msg(3, 1497 1497 "No need to insist_on_this_cd_number when the backup type isn't CD-R(W) or NFS or ISO"); 1498 1498 return; … … 1504 1504 if (g_ISO_restore_mode || bkpinfo->backup_media_type == iso 1505 1505 || bkpinfo->backup_media_type == nfs) { 1506 log_msg(3, "Remounting CD");1506 mr_msg(3, "Remounting CD"); 1507 1507 g_ISO_restore_mode = TRUE; 1508 1508 // FIXME --- I'm tempted to do something about this... … … 1520 1520 cd_number_i_want); 1521 1521 if (does_file_exist(tmp)) { 1522 log_msg(1,1522 mr_msg(1, 1523 1523 "FIXME - hacking bkpinfo->isodir from '%s' to /tmp/isodir", 1524 1524 bkpinfo->isodir); … … 1526 1526 } 1527 1527 } 1528 log_msg(3, "Mounting %s at %s", tmp, MNT_CDROM);1528 mr_msg(3, "Mounting %s at %s", tmp, MNT_CDROM); 1529 1529 if (mount_CDROM_here(tmp, MNT_CDROM)) { 1530 1530 fatal_error("Mommy!"); … … 1534 1534 } 1535 1535 if ((res = what_number_cd_is_this(bkpinfo)) != cd_number_i_want) { 1536 log_msg(3, "Currently, we hold %d but we want %d", res,1536 mr_msg(3, "Currently, we hold %d but we want %d", res, 1537 1537 cd_number_i_want); 1538 1538 sprintf(tmp, "Insisting on %s #%d", … … 1542 1542 media_descriptor_string(bkpinfo->backup_media_type), 1543 1543 cd_number_i_want); 1544 log_msg(3, tmp);1544 mr_msg(3, tmp); 1545 1545 while (what_number_cd_is_this(bkpinfo) != cd_number_i_want) { 1546 1546 paranoid_system("sync"); … … 1568 1568 paranoid_system("sync"); 1569 1569 } 1570 log_msg(1, "Thankyou. Proceeding...");1570 mr_msg(1, "Thankyou. Proceeding..."); 1571 1571 g_current_media_number = cd_number_i_want; 1572 1572 } … … 1627 1627 popup_and_OK("Please remove CD/floppy from drive(s)"); 1628 1628 } 1629 log_msg(3, "media type = %s",1629 mr_msg(3, "media type = %s", 1630 1630 bkptype_to_string(bkpinfo->backup_media_type)); 1631 1631 if (archiving_to_media) { … … 1664 1664 strcpy(tmp, "1"); 1665 1665 sprintf(sz_size, "%d", DEFAULT_DVD_DISK_SIZE); // 4.7 salesman's GB = 4.482 real GB = 4582 MB 1666 log_msg(1, "Setting to DVD defaults");1666 mr_msg(1, "Setting to DVD defaults"); 1667 1667 } else if (bkpinfo->backup_media_type == usb) { 1668 1668 strcpy(bkpinfo->media_device, VANILLA_USB_DEVICE); … … 1672 1672 strcpy(tmp, "4"); 1673 1673 strcpy(sz_size, "650"); 1674 log_msg(1, "Setting to CD defaults");1674 mr_msg(1, "Setting to CD defaults"); 1675 1675 } 1676 1676 if ((bkpinfo->backup_media_type != dvd) && (bkpinfo->backup_media_type != usb)) { … … 1699 1699 if (bkpinfo->disaster_recovery) { 1700 1700 strcpy(bkpinfo->media_device, "/dev/cdrom"); 1701 log_msg(2, "CD-ROM device assumed to be at %s",1701 mr_msg(2, "CD-ROM device assumed to be at %s", 1702 1702 bkpinfo->media_device); 1703 1703 } else if (bkpinfo->restore_data … … 1706 1706 strcpy(bkpinfo->media_device, "/dev/cdrom"); 1707 1707 } // just for the heck of it :) 1708 log_msg(1, "bkpinfo->media_device = %s",1708 mr_msg(1, "bkpinfo->media_device = %s", 1709 1709 bkpinfo->media_device); 1710 1710 if (bkpinfo->backup_media_type == dvd 1711 1711 || find_cdrom_device(bkpinfo->media_device, FALSE)) { 1712 log_msg(1, "bkpinfo->media_device = %s",1712 mr_msg(1, "bkpinfo->media_device = %s", 1713 1713 bkpinfo->media_device); 1714 1714 sprintf(comment, … … 1723 1723 } 1724 1724 } 1725 log_msg(2, "%s device found at %s",1725 mr_msg(2, "%s device found at %s", 1726 1726 media_descriptor_string(bkpinfo->backup_media_type), 1727 1727 bkpinfo->media_device); … … 1773 1773 1774 1774 if (find_tape_device_and_size(bkpinfo->media_device, sz_size)) { 1775 log_msg(3, "Ok, using vanilla scsi tape.");1775 mr_msg(3, "Ok, using vanilla scsi tape."); 1776 1776 strcpy(bkpinfo->media_device, VANILLA_SCSI_TAPE); 1777 1777 if ((fin = fopen(bkpinfo->media_device, "r"))) { … … 1816 1816 finish(1); 1817 1817 } 1818 log_msg(4, "sz_size = %s", sz_size);1818 mr_msg(4, "sz_size = %s", sz_size); 1819 1819 sz_size[0] = '\0'; 1820 1820 /* … … 1831 1831 friendly_sizestr_to_sizelong(sz_size) / 2 - 50; 1832 1832 } 1833 log_msg(4, "media_size[0] = %ld", bkpinfo->media_size[0]);1833 mr_msg(4, "media_size[0] = %ld", bkpinfo->media_size[0]); 1834 1834 if (bkpinfo->media_size[0] <= 0) { 1835 1835 bkpinfo->media_size[0] = 0; … … 1959 1959 finish(1); 1960 1960 } 1961 log_msg(3, "prefix set to %s", bkpinfo->prefix);1961 mr_msg(3, "prefix set to %s", bkpinfo->prefix); 1962 1962 1963 1963 for (i = 0; i <= MAX_NOOF_MEDIA; i++) { 1964 1964 bkpinfo->media_size[i] = 650; 1965 1965 } 1966 log_msg(3, "Just set nfs_remote_dir to %s",1966 mr_msg(3, "Just set nfs_remote_dir to %s", 1967 1967 bkpinfo->nfs_remote_dir); 1968 log_msg(3, "isodir is still %s", bkpinfo->isodir);1968 mr_msg(3, "isodir is still %s", bkpinfo->isodir); 1969 1969 break; 1970 1970 … … 2007 2007 finish(1); 2008 2008 } 2009 log_msg(3, "prefix set to %s", bkpinfo->prefix);2009 mr_msg(3, "prefix set to %s", bkpinfo->prefix); 2010 2010 break; 2011 2011 default: … … 2146 2146 bkpinfo->nfs_mount); 2147 2147 // strcpy(bkpinfo->isodir, call_program_and_get_last_line_of_output(tmp)); 2148 log_msg(3, "I think the NFS mount is mounted at %s",2148 mr_msg(3, "I think the NFS mount is mounted at %s", 2149 2149 bkpinfo->isodir); 2150 2150 } … … 2169 2169 fatal_error("Media size is less than zero."); 2170 2170 } else { 2171 log_msg(2, "Warning - media size is less than zero.");2171 mr_msg(2, "Warning - media size is less than zero."); 2172 2172 bkpinfo->media_size[0] = 0; 2173 2173 } … … 2354 2354 } 2355 2355 // assert_string_is_neither_NULL_nor_zerolength(dev); 2356 log_msg(10, "Injecting %s", dev);2356 mr_msg(10, "Injecting %s", dev); 2357 2357 inject_device(dev); 2358 2358 if (!does_file_exist(dev)) { 2359 log_msg(10, "%s doesn't exist. Returning FALSE.", dev);2359 mr_msg(10, "%s doesn't exist. Returning FALSE.", dev); 2360 2360 return (FALSE); 2361 2361 } … … 2365 2365 && !run_program_and_log_output(command, FALSE)) { 2366 2366 strcpy(output, dev); 2367 log_msg(4, "Found it - %s", dev);2367 mr_msg(4, "Found it - %s", dev); 2368 2368 return (TRUE); 2369 2369 } else { 2370 2370 output[0] = '\0'; 2371 log_msg(4, "It's not %s", dev);2371 mr_msg(4, "It's not %s", dev); 2372 2372 return (FALSE); 2373 2373 } … … 2646 2646 lstat(curr_fname, &statbuf); 2647 2647 while (S_ISLNK(statbuf.st_mode)) { 2648 log_msg(1, "curr_fname = %s", curr_fname);2648 mr_msg(1, "curr_fname = %s", curr_fname); 2649 2649 sprintf(command, "file %s", curr_fname); 2650 2650 strcpy(tmp, call_program_and_get_last_line_of_output(command)); … … 2655 2655 for (p = scratch; *p != '\0' && *p != '\''; p++); 2656 2656 *p = '\0'; 2657 log_msg(0, "curr_fname %s --> '%s' --> %s", curr_fname, tmp,2657 mr_msg(0, "curr_fname %s --> '%s' --> %s", curr_fname, tmp, 2658 2658 scratch); 2659 2659 if (scratch[0] == '/') { … … 2698 2698 malloc_string(command); 2699 2699 malloc_string(fdisk); 2700 log_msg(0, "Looking for partition table format type");2700 mr_msg(0, "Looking for partition table format type"); 2701 2701 sprintf(fdisk, "/sbin/parted2fdisk"); 2702 log_msg(1, "Using %s", fdisk);2702 mr_msg(1, "Using %s", fdisk); 2703 2703 sprintf(command, "%s -l %s | grep 'EFI GPT'", fdisk, drive); 2704 2704 strcpy(tmp, call_program_and_get_last_line_of_output(command)); … … 2708 2708 strcpy(output, "GPT"); 2709 2709 } 2710 log_msg(0, "Found %s partition table format type", output);2710 mr_msg(0, "Found %s partition table format type", output); 2711 2711 mr_free(command); 2712 2712 mr_free(tmp);
Note:
See TracChangeset
for help on using the changeset viewer.