Changeset 672 in MondoRescue for trunk/mondo/mondo


Ignore:
Timestamp:
Jun 12, 2006, 9:55:14 AM (18 years ago)
Author:
bcornec
Message:

merge -r651:671 $SVN_M/branches/stable

Location:
trunk/mondo/mondo/common
Files:
6 edited

Legend:

Unmodified
Added
Removed
  • trunk/mondo/mondo/common/libmondo-filelist.c

    r539 r672  
    12711271    /*@ int **************************************************** */
    12721272    int res = 0;
    1273     int *p_res = &res;
    1274 
    12751273    /*@ buffers ************************************************ */
    12761274
     
    13031301    if (res) {
    13041302        log_OS_error("Call to mondo-makefilelist failed");
    1305         *p_res++;
    13061303        mvaddstr_and_log_it(g_currentY++, 74, _("Failed."));
    13071304    } else {
  • trunk/mondo/mondo/common/libmondo-files.c

    r649 r672  
    11551155    fprintf(fout, "ipgateway=%s\n", nfs_client_defgw);
    11561156    fprintf(fout, "ipconf=\n");
     1157    fprintf(fout, "nfsmount=%s\n", bkpinfo->nfs_mount);
    11571158    fprintf(fout, "for i in `cat /proc/cmdline` ; do\n");
    11581159    fprintf(fout, "    echo $i | grep -qi ipconf= && ipconf=`echo $i | cut -d= -f2`\n");
     1160    fprintf(fout, "    echo $i | grep -qi nfsmount= && nfsmount=`echo $i | cut -d= -f2`\n");
    11591161    fprintf(fout, "done\n");
     1162    fprintf(fout, "nfs_server_ipaddr=`echo $nfsmount | cut -d: -f1`\n");
    11601163    fprintf(fout, "echo \"$ipconf\" | grep -q \"dhcp\"\n");
    1161     fprintf(fout, "if [ $? = 0 ]; then\n");
     1164    fprintf(fout, "if [ $? -eq 0 ]; then\n");
    11621165    fprintf(fout, "    ipdev=`echo $ipconf | cut -d: -f1`\n");
     1166    fprintf(fout, "    echo \"Making DHCP request on $ipdev\"\n");
    11631167    fprintf(fout, "    udhcpc -i $ipdev\n");
    11641168    fprintf(fout, "else\n");
     
    11731177    fprintf(fout, "    route add default gw $ipgateway\n");
    11741178    fprintf(fout, "fi\n");
    1175     fprintf(fout, "ping -c $ipcount %s  # ping server\n", nfs_server_ipaddr);
    1176     fprintf(fout, "mount -t nfs -o nolock %s /tmp/isodir\n",
    1177             bkpinfo->nfs_mount);
     1179    fprintf(fout, "ping -c $ipcount $nfs_server_ipaddr # ping server\n");
     1180    fprintf(fout, "mount -t nfs -o nolock $nfsmount /tmp/isodir\n");
    11781181    paranoid_fclose(fout);
    11791182    chmod(outfile, 0777);
  • trunk/mondo/mondo/common/libmondo-raid.c

    r588 r672  
    967967    // trim leading spaces
    968968    pos = string;
    969     while (*pos == ' ') *pos++;
    970     asprintf(&string, pos);
    971     //
     969    while (*pos == ' ') pos += 1;
     970    asprintf(&strtmp, pos);
     971    strcpy(string, strtmp);
     972    paranoid_free(strtmp);
    972973    // if we have newline after only spaces, this is a blank line, update
    973974    // counters, otherwise do normal parsing
     
    11241125    } else {
    11251126      while (*pos != ' ') {
    1126         *pos--;
     1127        pos -= 1;
    11271128        if (pos < string) {
    11281129          log_it("String underflow!\n");
     
    11491150    } else {
    11501151      while (*pos != ' ') {
    1151         *pos--;
     1152        pos -= 1;
    11521153        if (pos < string) {
    11531154          printf("ERROR: String underflow!\n");
  • trunk/mondo/mondo/common/libmondo-string.c

    r561 r672  
    11601160token = malloc(sizeof(*token)*(pos1+1));
    11611161strncpy(token, strptr, pos1);
     1162token[pos1] = '\0';
    11621163*lastpos = *lastpos + pos1 + pos2 + 1;
    11631164
  • trunk/mondo/mondo/common/libmondo-tools.c

    r561 r672  
    506506        }
    507507        if (bkpinfo->nonbootable_backup) {
    508             asprintf(&mondo_mkisofs_sz, MONDO_MKISOFS_NONBOOT);
     508            asprintf(&mondo_mkisofs_sz, "%s -r -p MondoRescue -publisher www.mondorescue.org -A Mondo_Rescue_GPL_Version -V _CD#_", mrconf->mondo_iso_creation_cmd);
    509509        } else if
    510510#ifdef __FreeBSD__
  • trunk/mondo/mondo/common/my-stuff.h

    r561 r672  
    210210 */
    211211#define MONDO_MKISOFS_REGULAR_SYSLINUX  "mkisofs -J -boot-info-table -no-emul-boot -b isolinux.bin -c boot.cat -boot-load-size 4 -r -p MondoRescue -publisher www.mondorescue.org -A Mondo_Rescue_GPL_Version -V _CD#_"
     212#define MONDO_MKISOFS_REGULAR_LILO      "mkisofs -J -boot-info-table -no-emul-boot -b isolinux.bin -c boot.cat -boot-load-size 4 -r -p MondoRescue -publisher www.mondorescue.org -A Mondo_Rescue_GPL -V _CD#_"
     213#define MONDO_MKISOFS_REGULAR_ELILO     "mkisofs -no-emul-boot -b images/mindi-bootroot.8192.img -c boot.cat -J -r -p MondoRescue -publisher www.mondorescue.org -A Mondo_Rescue_GPL -V _CD#_"
    212214
    213215/**
     
    215217 */
    216218// -b images/mindi-boot.2880.img
    217 #define MONDO_MKISOFS_REGULAR_LILO      "mkisofs -boot-info-table -no-emul-boot -b isolinux.bin -c boot.cat -boot-load-size 4 -J -r -p MondoRescue -publisher www.mondorescue.org -A Mondo_Rescue_GPL -V _CD#_"
    218219
    219220/**
     
    222223// -b images/mindi-boot.2880.img
    223224// Should replace 8192 by IA64_BOOT_SIZE
    224 #define MONDO_MKISOFS_REGULAR_ELILO      "mkisofs -no-emul-boot -b images/mindi-bootroot.8192.img -c boot.cat -J -r -p MondoRescue -publisher www.mondorescue.org -A Mondo_Rescue_GPL -V _CD#_"
    225225
    226226/**
Note: See TracChangeset for help on using the changeset viewer.