From: Hugo Villeneuve Date: Wed, 21 Oct 2009 15:22:19 +0000 (+0000) Subject: Forbid enabling use_ssl=1 in configuration file if SSL is not compiled in X-Git-Tag: v1.0.0~9 X-Git-Url: http://gitweb.hugovil.com/?a=commitdiff_plain;h=74e55fcdb8030a39a604cde700bfb85dbbb82474;p=dockapps%2Fwmnotify.git Forbid enabling use_ssl=1 in configuration file if SSL is not compiled in --- diff --git a/src/configfile.c b/src/configfile.c index 06c979d..f2e5a2b 100644 --- a/src/configfile.c +++ b/src/configfile.c @@ -216,10 +216,16 @@ ParseConfigurationFile( FILE *file ) wmnotify_infos.use_ssl = false; } else if( number == 1 ) { +#if HAVE_SSL wmnotify_infos.use_ssl = true; +#else + fprintf( stderr, "%s error: You must compile %s with SSL support to\n" \ + "set parameter 'use_ssl' to true in configuration file\n", PACKAGE, PACKAGE ); + exit( EXIT_FAILURE ); +#endif } else { - fprintf( stderr, "%s: Invalid value for for parameter 'enablebeep' in\n" \ + fprintf( stderr, "%s: Invalid value for for parameter 'use_ssl' in\n" \ "configuration file (must be 0 or 1): %d\n", PACKAGE, number ); exit( EXIT_FAILURE ); }