Changeset 274 in MondoRescue for trunk/mondo/mondo/mondorestore


Ignore:
Timestamp:
Jan 3, 2006, 4:15:54 PM (18 years ago)
Author:
bcornec
Message:

merge -r272:273 $SVN_M/branches/2.06

Location:
trunk/mondo/mondo/mondorestore
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/mondo/mondo/mondorestore/mondo-restore.c

    r252 r274  
    31013101    fatal_error("This will fail");
    31023102    sprintf(command,
    3103             "cat %s | grep -x \"%s.*\" > %s",
    3104             g_filelist_full, restore_this_directory, g_filelist_full);
     3103            "grep -x \"%s.*\" %s > %s",
     3104            restore_this_directory, g_filelist_full, g_filelist_full);
    31053105    if (system(command)) {
    31063106        retval++;
     
    31113111    fatal_error("This will fail");
    31123112    sprintf(command,
    3113             "cat %s | grep -x \"%s.*\" > %s",
    3114             g_biggielist_txt, restore_this_directory, g_biggielist_txt);
     3113            "grep -x \"%s.*\" %s > %s",
     3114            restore_this_directory, g_biggielist_txt, g_biggielist_txt);
    31153115    if (system(command)) {
    31163116        log_msg(1,
  • trunk/mondo/mondo/mondorestore/mondo-rstr-newt.c

    r181 r274  
    553553    assert(raidrec != NULL);
    554554    system
    555         ("cat /proc/mdstat | grep Pers > /tmp/raid-personalities.txt 2> /dev/null");
     555        ("grep Pers /proc/mdstat > /tmp/raid-personalities.txt 2> /dev/null");
    556556    strcpy(personalities,
    557557           last_line_of_file("/tmp/raid-personalities.txt"));
  • trunk/mondo/mondo/mondorestore/mondo-rstr-tools.c

    r254 r274  
    382382            f, file);
    383383    log_msg(2, tmp);
    384     sprintf(command, "cat %s | grep -x \"%s\"", list_fname, file);
     384    sprintf(command, "grep -x \"%s\" %s", file, list_fname);
    385385    res = run_program_and_log_output(command, FALSE);
    386386    paranoid_free(command);
     
    540540    }
    541541    sprintf(newfile_fname, "%s/rc.local.mondorescue", path);
    542     sprintf(tmp, "cat %s | grep mondorescue > /dev/null 2> /dev/null",
     542    sprintf(tmp, "grep mondorescue %s > /dev/null 2> /dev/null",
    543543            rclocal_fname);
    544544    if (system(tmp)) {
     
    551551\\n\
    552552\\n\
    553 cat %s | grep -v mondorescue > %s\\n\
     553grep -v mondorescue %s > %s\\n\
    554554rm -f /var/lock/subsys/*xfs*\\n\
    555555rm -f /var/run/xfs.*\\n\
     
    13531353            paranoid_system(command);
    13541354        }
    1355         sprintf(command, "cat %s | grep  -x \"/dev/.*\" > %s",
     1355        sprintf(command, "grep  -x \"/dev/.*\" %s > %s",
    13561356                g_biggielist_txt, g_filelist_imagedevs);
    13571357        paranoid_system(command);
Note: See TracChangeset for help on using the changeset viewer.