diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2005-08-05 07:22:10 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2005-08-05 07:22:10 +0000 |
commit | 3ec864159a1792df642a75611363c39fb1fd1cd3 (patch) | |
tree | 2441b71b8b443445b7bb1c5d4ac464e70679577f /src/mbox.c | |
parent | 6247f6269afff27ecfe2ca9650e151f440ec806a (diff) |
enabled compilation with MinGW.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@469 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src/mbox.c')
-rw-r--r-- | src/mbox.c | 6 |
1 files changed, 6 insertions, 0 deletions
@@ -380,17 +380,23 @@ gint copy_mbox(const gchar *src, const gchar *dest) void empty_mbox(const gchar *mbox) { +#if HAVE_TRUNCATE if (truncate(mbox, 0) < 0) { +#endif FILE *fp; +#if HAVE_TRUNCATE FILE_OP_ERROR(mbox, "truncate"); +#endif if ((fp = fopen(mbox, "wb")) == NULL) { FILE_OP_ERROR(mbox, "fopen"); g_warning(_("can't truncate mailbox to zero.\n")); return; } fclose(fp); +#if HAVE_TRUNCATE } +#endif } /* read all messages in SRC, and store them into one MBOX file. */ |