comparison src/readpst.c @ 350:7a91e30826d8 stable-0-6-65

Hans Liss - debug level output
author Carl Byington <carl@five-ten-sg.com>
date Fri, 11 Sep 2015 10:18:03 -0700
parents a57c15b3108a
children 09dd5299d91c
comparison
equal deleted inserted replaced
349:a57c15b3108a 350:7a91e30826d8
418 } 418 }
419 419
420 } else if (item->message_store) { 420 } else if (item->message_store) {
421 // there should only be one message_store, and we have already done it 421 // there should only be one message_store, and we have already done it
422 ff.skip_count++; 422 ff.skip_count++;
423 DEBUG_INFO(("item with message store content, type %i %s folder type %i, skipping it\n", item->type, item->ascii_type, ff.type)); 423 DEBUG_WARN(("item with message store content, type %i %s folder type %i, skipping it\n", item->type, item->ascii_type, ff.type));
424 424
425 } else { 425 } else {
426 ff.skip_count++; 426 ff.skip_count++;
427 DEBUG_INFO(("Unknown item type %i (%s) name (%s)\n", 427 DEBUG_WARN(("Unknown item type %i (%s) name (%s)\n",
428 item->type, item->ascii_type, item->file_as.str)); 428 item->type, item->ascii_type, item->file_as.str));
429 } 429 }
430 pst_freeItem(item); 430 pst_freeItem(item);
431 } 431 }
432 close_enter_dir(&ff); 432 close_enter_dir(&ff);
451 printf("cannot compile regex pattern to find content charset in html bodies\n"); 451 printf("cannot compile regex pattern to find content charset in html bodies\n");
452 exit(3); 452 exit(3);
453 } 453 }
454 454
455 // command-line option handling 455 // command-line option handling
456 while ((c = getopt(argc, argv, "a:bC:c:Dd:emhj:kMo:qrSt:uVw8"))!= -1) { 456 while ((c = getopt(argc, argv, "a:bC:c:Dd:emhj:kMo:qrSt:uVwL:8"))!= -1) {
457 switch (c) { 457 switch (c) {
458 case 'a': 458 case 'a':
459 if (optarg) { 459 if (optarg) {
460 int n = strlen(optarg); 460 int n = strlen(optarg);
461 acceptable_extensions = (char*)pst_malloc(n+2); 461 acceptable_extensions = (char*)pst_malloc(n+2);
521 mode = MODE_SEPARATE; 521 mode = MODE_SEPARATE;
522 mode_MH = 1; 522 mode_MH = 1;
523 mode_EX = 1; 523 mode_EX = 1;
524 mode_MSG = 0; 524 mode_MSG = 0;
525 file_name_len = 14; 525 file_name_len = 14;
526 break;
527 case 'L':
528 pst_debug_setlevel(atoi(optarg));
526 break; 529 break;
527 case 'm': 530 case 'm':
528 mode = MODE_SEPARATE; 531 mode = MODE_SEPARATE;
529 mode_MH = 1; 532 mode_MH = 1;
530 mode_EX = 1; 533 mode_EX = 1;
743 printf("Usage: %s [OPTIONS] {PST FILENAME}\n", prog_name); 746 printf("Usage: %s [OPTIONS] {PST FILENAME}\n", prog_name);
744 printf("OPTIONS:\n"); 747 printf("OPTIONS:\n");
745 printf("\t-V\t- Version. Display program version\n"); 748 printf("\t-V\t- Version. Display program version\n");
746 printf("\t-C charset\t- character set for items with an unspecified character set\n"); 749 printf("\t-C charset\t- character set for items with an unspecified character set\n");
747 printf("\t-D\t- Include deleted items in output\n"); 750 printf("\t-D\t- Include deleted items in output\n");
751 printf("\t-L <level> \t- Set debug level; 1=debug,2=info,3=warn.\n");
748 printf("\t-M\t- Write emails in the MH (rfc822) format\n"); 752 printf("\t-M\t- Write emails in the MH (rfc822) format\n");
749 printf("\t-S\t- Separate. Write emails in the separate format\n"); 753 printf("\t-S\t- Separate. Write emails in the separate format\n");
750 printf("\t-a <attachment-extension-list>\t- Discard any attachment without an extension on the list\n"); 754 printf("\t-a <attachment-extension-list>\t- Discard any attachment without an extension on the list\n");
751 printf("\t-b\t- Don't save RTF-Body attachments\n"); 755 printf("\t-b\t- Don't save RTF-Body attachments\n");
752 printf("\t-c[v|l]\t- Set the Contact output mode. -cv = VCard, -cl = EMail list\n"); 756 printf("\t-c[v|l]\t- Set the Contact output mode. -cv = VCard, -cl = EMail list\n");