mutt stable branch with some hacks
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Convert shrink_histfile() tempfile to use buffer pool.

+7 -5
+7 -5
history.c
··· 188 188 189 189 static void shrink_histfile (void) 190 190 { 191 - char tmpfname[_POSIX_PATH_MAX]; 191 + BUFFER *tmpfname = NULL; 192 192 FILE *f, *tmp = NULL; 193 193 int n[HC_LAST] = { 0 }; 194 194 int line, hclass, read; ··· 236 236 237 237 if (regen_file) 238 238 { 239 - mutt_mktemp (tmpfname, sizeof (tmpfname)); 240 - if ((tmp = safe_fopen (tmpfname, "w+")) == NULL) 239 + tmpfname = mutt_buffer_pool_get (); 240 + mutt_buffer_mktemp (tmpfname); 241 + if ((tmp = safe_fopen (mutt_b2s (tmpfname), "w+")) == NULL) 241 242 { 242 - mutt_perror (tmpfname); 243 + mutt_perror (mutt_b2s (tmpfname)); 243 244 goto cleanup; 244 245 } 245 246 rewind (f); ··· 277 278 safe_fclose (&f); 278 279 } 279 280 safe_fclose (&tmp); 280 - unlink (tmpfname); 281 + unlink (mutt_b2s (tmpfname)); 281 282 } 283 + mutt_buffer_pool_release (&tmpfname); 282 284 if (option (OPTHISTREMOVEDUPS)) 283 285 for (hclass = 0; hclass < HC_LAST; hclass++) 284 286 hash_destroy (&dup_hashes[hclass], NULL);