Changeset 1042
- Timestamp:
- 07/10/07 11:49:48 (1 year ago)
- Files:
-
- 1.8.2/branches/devel/src/extmail.c (modified) (4 diffs)
- 1.8.2/branches/devel/src/warnings.c (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
1.8.2/branches/devel/src/extmail.c
r1010 r1042 2543 2543 /* Return a longer description of message flags */ 2544 2544 static char tbuf1[BUFFER_LEN]; 2545 2546 tbuf1[0] = '\0'; 2545 char *tp; 2546 2547 tp = tbuf1; 2547 2548 if (Read(mp)) 2548 s trcat(tbuf1, T("Read "));2549 safe_str(T("Read "), tbuf1, &tp); 2549 2550 else 2550 s trcat(tbuf1, T("Unread "));2551 safe_str(T("Unread "), tbuf1, &tp); 2551 2552 if (Cleared(mp)) 2552 s trcat(tbuf1, T("Cleared "));2553 safe_str(T("Cleared "), tbuf1, &tp); 2553 2554 if (Urgent(mp)) 2554 s trcat(tbuf1, T("Urgent "));2555 safe_str(T("Urgent "), tbuf1, &tp); 2555 2556 if (Mass(mp)) 2556 s trcat(tbuf1, T("Mass "));2557 safe_str(T("Mass "), tbuf1, &tp); 2557 2558 if (Forward(mp)) 2558 s trcat(tbuf1, T("Fwd "));2559 safe_str(T("Fwd "), tbuf1, &tp); 2559 2560 if (Tagged(mp)) 2560 strcat(tbuf1, T("Tagged")); 2561 safe_str(T("Tagged"), tbuf1, &tp); 2562 *tp = '\0'; 2561 2563 return tbuf1; 2562 2564 } … … 2803 2805 2804 2806 /* Handle this now so it doesn't clutter code */ 2805 tbuf1[0] = '\0';2807 j = 0; 2806 2808 if (flags & M_URGENT) 2807 strcat(tbuf1, "U");2809 tbuf1[j++] = 'U'; 2808 2810 if (flags & M_FORWARD) 2809 strcat(tbuf1, "F");2811 tbuf1[j++] = 'F'; 2810 2812 if (flags & M_REPLY) 2811 strcat(tbuf1, "R"); 2812 2813 arg = (char *) mush_malloc(BUFFER_LEN, "string"); 2814 arg2 = (char *) mush_malloc(BUFFER_LEN, "string"); 2815 arg3 = (char *) mush_malloc(BUFFER_LEN, "string"); 2816 arg4 = (char *) mush_malloc(BUFFER_LEN, "string"); 2813 tbuf1[j++] = 'R'; 2814 tbuf1[j] = '\0'; 2815 2816 arg = mush_malloc(BUFFER_LEN, "string"); 2817 arg2 = mush_malloc(BUFFER_LEN, "string"); 2818 arg3 = mush_malloc(BUFFER_LEN, "string"); 2819 arg4 = mush_malloc(BUFFER_LEN, "string"); 2817 2820 if (!arg4) 2818 2821 mush_panic("Unable to allocate memory in mailfilter"); … … 2837 2840 PE_DEFAULT, PT_DEFAULT, NULL); 2838 2841 *bp = '\0'; 2839 free( (Malloc_t)asave);2842 free(asave); 2840 2843 if (*buff) { 2841 2844 sprintf(buf, "0:%d", mailnumber); … … 2843 2846 } 2844 2847 2845 mush_free( (Malloc_t)arg, "string");2846 mush_free( (Malloc_t)arg2, "string");2847 mush_free( (Malloc_t)arg3, "string");2848 mush_free( (Malloc_t)arg4, "string");2848 mush_free(arg, "string"); 2849 mush_free(arg2, "string"); 2850 mush_free(arg3, "string"); 2851 mush_free(arg4, "string"); 2849 2852 restore_global_env("filter_mail", wsave); 2850 2853 restore_global_regs("filter_mail", rsave); 1.8.2/branches/devel/src/warnings.c
r1010 r1042 377 377 { 378 378 static char tbuf1[BUFFER_LEN]; 379 char *tp; 379 380 int listsize, indexx; 380 381 381 t buf1[0] = '\0';382 tp = tbuf1; 382 383 383 384 /* Get the # of elements in checklist */ … … 391 392 * if the bits set on the_flag is a subset of the bits set on warns 392 393 */ 393 s trcat(tbuf1, checklist[indexx].name);394 s trcat(tbuf1, " ");394 safe_str(checklist[indexx].name, tbuf1, &tp); 395 safe_chr(' ', tbuf1, &tp); 395 396 /* If we've got a flag which subsumes smaller ones, don't 396 397 * list the smaller ones
