diff options
author | Wilmer van der Gaast <wilmer@gaast.net> | 2008-06-30 00:41:39 +0100 |
---|---|---|
committer | Wilmer van der Gaast <wilmer@gaast.net> | 2008-06-30 00:41:39 +0100 |
commit | f5d1b3185140e690a6503b9e68c7ea28655b405e (patch) | |
tree | f679a139ecca219aa2c7a07adcaefd3000c8c801 /storage_xml.c | |
parent | cd63d5822e76a6126bb3017567c9ce2869a44e0b (diff) | |
parent | 913545e54123296fb8229ecad2c77a6e899e0242 (diff) |
Merging changes from Jelmer: It's now possible to cross-compile a Windows
version of BitlBee from Linux. No working SSL support yet though!
Diffstat (limited to 'storage_xml.c')
-rw-r--r-- | storage_xml.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/storage_xml.c b/storage_xml.c index ca82a9d1..cb92135c 100644 --- a/storage_xml.c +++ b/storage_xml.c @@ -30,6 +30,11 @@ #include "md5.h" #include <glib/gstdio.h> +#if !GLIB_CHECK_VERSION(2,8,0) +/* GLib < 2.8.0 doesn't have g_access, so just use the system access(). */ +#define g_access access +#endif + typedef enum { XML_PASS_CHECK_ONLY = -1, @@ -245,7 +250,8 @@ static void xml_init( void ) { if( ! g_file_test( global.conf->configdir, G_FILE_TEST_EXISTS ) ) log_message( LOGLVL_WARNING, "The configuration directory `%s' does not exist. Configuration won't be saved.", global.conf->configdir ); - else if( ! g_file_test( global.conf->configdir, G_FILE_TEST_EXISTS ) || g_access( global.conf->configdir, W_OK ) != 0 ) + else if( ! g_file_test( global.conf->configdir, G_FILE_TEST_EXISTS ) || + g_access( global.conf->configdir, W_OK ) != 0 ) log_message( LOGLVL_WARNING, "Permission problem: Can't read/write from/to `%s'.", global.conf->configdir ); } |