diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2009-03-16 02:54:54 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2009-03-16 02:54:54 +0000 |
commit | 3ad4efad565998dda3a31d9d4d2a4dceda980aac (patch) | |
tree | 9f9e463dc38434e3618b55d6fc4b031e47647cc3 /libsylph | |
parent | 3fbaadae0b540884a19da369b14bedc607164384 (diff) |
unix: fixed infinite loop bug.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@2120 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'libsylph')
-rw-r--r-- | libsylph/mh.c | 2 | ||||
-rw-r--r-- | libsylph/utils.c | 4 | ||||
-rw-r--r-- | libsylph/utils.h | 4 |
3 files changed, 6 insertions, 4 deletions
diff --git a/libsylph/mh.c b/libsylph/mh.c index 4b68cd3a..abbfc23d 100644 --- a/libsylph/mh.c +++ b/libsylph/mh.c @@ -459,7 +459,7 @@ static gint mh_add_msgs(Folder *folder, FolderItem *dest, GSList *file_list, if (first_ == 0 || first_ > dest->last_num + 1) first_ = dest->last_num + 1; - if (g_link(fileinfo->file, destfile) < 0) { + if (syl_link(fileinfo->file, destfile) < 0) { if (copy_file(fileinfo->file, destfile, TRUE) < 0) { g_warning(_("can't copy message %s to %s\n"), fileinfo->file, destfile); diff --git a/libsylph/utils.c b/libsylph/utils.c index 208458ea..d67ff14d 100644 --- a/libsylph/utils.c +++ b/libsylph/utils.c @@ -152,7 +152,8 @@ gint g_chmod(const gchar *path, gint mode) } #endif /* GLIB_CHECK_VERSION && G_OS_UNIX */ -gint g_link(const gchar *src, const gchar *dest) +#ifndef G_OS_UNIX +gint syl_link(const gchar *src, const gchar *dest) { #ifdef G_OS_WIN32 wchar_t *wsrc; @@ -208,6 +209,7 @@ gint g_link(const gchar *src, const gchar *dest) return link(src, dest); #endif } +#endif /* !G_OS_UNIX */ void list_free_strings(GList *list) { diff --git a/libsylph/utils.h b/libsylph/utils.h index 6788c3d6..97221fb9 100644 --- a/libsylph/utils.h +++ b/libsylph/utils.h @@ -68,9 +68,9 @@ gint g_chmod (const gchar *path, #endif /* !GLIB_CHECK_VERSION */ #ifdef G_OS_UNIX -#define g_link link +#define syl_link link #else -gint g_link (const gchar *src, +gint syl_link (const gchar *src, const gchar *dest); #endif |