diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2015-02-06 02:33:02 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2015-02-06 02:33:02 +0000 |
commit | 2d4c4fca2583bbc54bc3f76daca1b93d922391c7 (patch) | |
tree | 7e100aa81a3dc4ebc1901d6d71eb2df1766eec28 | |
parent | dc3e933ec4b73ac93ae866bb979f02045181a17f (diff) |
Fixed _s_tempnam().
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@3463 ee746299-78ed-0310-b773-934348b2243d
-rw-r--r-- | ChangeLog | 5 | ||||
-rw-r--r-- | libsylph/utils.c | 5 |
2 files changed, 8 insertions, 2 deletions
@@ -1,3 +1,8 @@ +2015-02-06 + + * libsylph/utils.c: _s_tempnam(): memory allocated by _wtempnam() + must be freed by MSVCRT, not by GLib (thanks to Gisle Vanem). + 2015-01-16 * src/gtkutils.c: gtkut_text_buffer_insert_with_tag_by_name(): diff --git a/libsylph/utils.c b/libsylph/utils.c index 3c54611c..0faf6b48 100644 --- a/libsylph/utils.c +++ b/libsylph/utils.c @@ -3745,7 +3745,8 @@ gchar *_s_tempnam(const gchar *dir, const gchar *prefix) save_errno = EINVAL; } - g_free(wname); + free(wname); /* must be freed by same MSVCRT used for + _wtempnam() */ g_free(wprefix); g_free(wpath); @@ -3779,7 +3780,7 @@ gchar *_s_tempnam(const gchar *dir, const gchar *prefix) save_errno = EINVAL; } - g_free(cp_name); + free(cp_name); g_free(cp_prefix); g_free(cp_path); |