Changeset 1132


Ignore:
Timestamp:
Feb 11, 2007, 2:33:58 AM (12 years ago)
Author:
bruno
Message:

mondoarchive now uses mr_msg_init

Location:
branches/stable/mondo/src
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/stable/mondo/src/lib/mr_msg.c

    r1104 r1132  
    3333
    3434/* Initialization function for messages */
    35 void mr_msg_init(const char *configfile, int loglevel) {
     35void mr_msg_init(const char *logfile, int loglevel) {
    3636    FILE *fout = NULL;
    3737    int res = 0;
    3838
    39     asprintf(&mr_logfile,configfile);
     39    asprintf(&mr_logfile,logfile);
    4040    if ((fout = fopen(mr_logfile, "w")) == NULL) {
    4141        fprintf(stderr,"Unable to write to %s\n",mr_logfile);
  • branches/stable/mondo/src/mondoarchive/main.c

    r1112 r1132  
    186186    say_at_end[0] = '\0';
    187187    printf("Initializing...\n");
    188     bkpinfo = mr_malloc(sizeof(struct s_bkpinfo));
    189188
    190189    /* initialize log file with time stamp */
    191190    unlink(MONDO_LOGFILE);
     191    mr_msg_init(MONDO_LOGFILE,4);
    192192    mr_msg(0, "Time started: %s", mr_date());
     193
     194    bkpinfo = mr_malloc(sizeof(struct s_bkpinfo));
    193195
    194196    /* make sure PATH environmental variable allows access to mkfs, fdisk, etc. */
     
    456458    /* finalize log file with time stamp */
    457459    mr_msg(0, "Time finished: %s", mr_date());
     460    mr_msg_close();
    458461
    459462    if (!g_text_mode) {
Note: See TracChangeset for help on using the changeset viewer.