Mercurial > libpst
diff src/readpst.c @ 33:12cac756bc05 stable-0-5-5
enable -d option, but if not specified, don't generate a debug file
author | carl |
---|---|
date | Tue, 10 Jul 2007 20:23:55 -0700 |
parents | b88ceb81dba2 |
children | 07177825c91b |
line wrap: on
line diff
--- a/src/readpst.c Tue Jul 10 18:18:38 2007 -0700 +++ b/src/readpst.c Tue Jul 10 20:23:55 2007 -0700 @@ -202,13 +202,11 @@ } #ifdef DEBUG_ALL - // initialize log file - if (!d_log) - d_log = "readpst.log"; + // force a log file + if (!d_log) d_log = "readpst.log"; +#endif // defined DEBUG_ALL DEBUG_INIT(d_log); DEBUG_REGISTER_CLOSE(); -#endif // defined DEBUG_ALL - DEBUG_ENT("main"); if (argc > optind) { @@ -275,10 +273,6 @@ item = NULL; } - /* if ((item = _pst_parse_item(&pstfile, d_ptr)) == NULL || item->folder == NULL) { - DEBUG_MAIN(("main: Could not get \"Top Of Personal Folder\" record\n")); - return -2; - }*/ d_ptr = d_ptr->child; // do the children of TOPF if (output_mode != OUTPUT_QUIET) printf("Processing items...\n"); @@ -328,8 +322,7 @@ skip_child = 1; } else { DEBUG_MAIN(("main: Folder has NO children. Creating directory, and closing again\n")); - if (output_mode != OUTPUT_QUIET) - printf("\tNo items to process in folder \"%s\", should have been %i\n", f->dname, f->stored_count); + if (output_mode != OUTPUT_QUIET) printf("\tNo items to process in folder \"%s\", should have been %i\n", f->dname, f->stored_count); head = f->next; if (f->output) fclose(f->output);