diff --git a/glib/gfileutils.c b/glib/gfileutils.c index 441e1753d..adf83d32e 100644 --- a/glib/gfileutils.c +++ b/glib/gfileutils.c @@ -1122,7 +1122,7 @@ write_to_temp_file (const gchar *contents, #endif errno = 0; - if (g_close (fd, err)) + if (!g_close (fd, err)) { g_unlink (tmp_name);