From 4b58fae540284062ef1dbd4afac5e6f4137aad00 Mon Sep 17 00:00:00 2001 From: "Leandro A. F. Pereira" Date: Fri, 6 Apr 2007 17:03:54 +0000 Subject: Late-minute fixes --- hardinfo2/syncmanager.c | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'hardinfo2/syncmanager.c') diff --git a/hardinfo2/syncmanager.c b/hardinfo2/syncmanager.c index d2714741..6602407a 100644 --- a/hardinfo2/syncmanager.c +++ b/hardinfo2/syncmanager.c @@ -26,6 +26,7 @@ #include #include +#include typedef struct _SyncDialog SyncDialog; typedef struct _SyncNetArea SyncNetArea; @@ -283,7 +284,19 @@ static void _action_call_function_got_response(SoupMessage *msg, gpointer user_d DEBUG("saving to %s", filename); +#ifdef g_file_set_contents g_file_set_contents(filename, string, -1, NULL); +#else + { + FILE *f; + + f = fopen(filename, "w+"); + if (f) { + fwrite(string, 1, strlen(string), f); + fclose(f); + } + } +#endif g_free(filename); } -- cgit v1.2.3