Changeset 783 in MondoRescue for trunk/mondo/mondo/common/libmondo-verify.c


Ignore:
Timestamp:
Aug 31, 2006, 5:09:20 PM (18 years ago)
Author:
Bruno Cornec
Message:
  • Massive rewrite continues for memory management.
  • main structure should now have all parameters allocated dynamically
  • new lib libmr.a + dir + build process reviewed to support it.
  • new include subdir to host external definitions of the new lib
  • code now compiles. Still one remaining link issues for mondorestore. This should allow for some tests soon.

(goal is to separate completely reviewed code and functions and provide clean interfaces)

File:
1 edited

Legend:

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

    r688 r783  
    6363    sync();
    6464
    65 /*  sprintf (command,
     65/*  s-printf (command,
    6666       "grep \"afio: \" %s | awk '{j=substr($0,8); i=index(j,\": \");printf \"/%%s\\n\",substr(j,1,i-2);}' | sort -u | grep -v \"incheckentry.*xwait\" | grep -vx \"/afio:.*\" | grep -vx \"/dev/.*\" > %s",
    6767       stderr_fname, afio_found_changes);
     
    152152    }
    153153    asprintf(&tmp, "Verifying %s #%d's tarballs",
    154              media_descriptor_string(bkpinfo->backup_media_type),
     154             bkpinfo->backup_media_string,
    155155             g_current_media_number);
    156156    open_evalcall_form(tmp);
     
    187187 * - @c restore_path
    188188 * - @c use_lzo
    189  * - @c zip_exe
    190189 * - @c zip_suffix
    191190 * @param mtpt The mountpoint the CD/DVD/ISO is mounted on.
     
    245244    iamhere("before vsbf");
    246245    asprintf(&tmp, "Verifying %s#%d's big files",
    247              media_descriptor_string(bkpinfo->backup_media_type),
     246             bkpinfo->backup_media_string,
    248247             g_current_media_number);
    249248    open_evalcall_form(tmp);
     
    391390    /*@ long *********************************************************** */
    392391    long diffs = 0;
    393     /*  getcwd(old_pwd,MAX_STR_LEN-1); */
    394392
    395393    assert(bkpinfo != NULL);
     
    405403        && strcmp(bkpinfo->zip_suffix, "lzo")) {
    406404        log_msg(2, "OK, I'm going to start using lzop.");
    407         strcpy(bkpinfo->zip_exe, "lzop");
    408         strcpy(bkpinfo->zip_suffix, "lzo");
     405        paranoid_alloc(bkpinfo->zip_exe, "lzop");
     406        paranoid_alloc(bkpinfo->zip_suffix, "lzo");
    409407        bkpinfo->use_lzo = TRUE;
    410408    }
     
    412410        && strcmp(bkpinfo->zip_suffix, "bz2")) {
    413411        log_msg(2, "OK, I'm going to start using bzip2.");
    414         strcpy(bkpinfo->zip_exe, "bzip2");
    415         strcpy(bkpinfo->zip_suffix, "bz2");
     412        paranoid_alloc(bkpinfo->zip_exe, "bzip2");
     413        paranoid_alloc(bkpinfo->zip_suffix, "bz2");
    416414        bkpinfo->use_lzo = FALSE;
    417415    }
     
    478476
    479477    /*  chdir(old_pwd); */
    480     //  sprintf (tmp, "uniq -u %s >> %s", "/tmp/mondo-verify.err", MONDO_LOGFILE);
     478    //  s-printf (tmp, "uniq -u %s >> %s", "/tmp/mondo-verify.err", MONDO_LOGFILE);
    481479    //  paranoid_system (tmp);
    482480    //  unlink ("/tmp/mondo-verify.err");
Note: See TracChangeset for help on using the changeset viewer.