From 9ecf9c624c5272cf8d576ec173283ebfe72fd373 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Thu, 1 Dec 2016 03:23:03 +0100 Subject: Fix warnings MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/cg-gamma.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) (limited to 'src/cg-gamma.c') diff --git a/src/cg-gamma.c b/src/cg-gamma.c index 8f4a361..b8df95d 100644 --- a/src/cg-gamma.c +++ b/src/cg-gamma.c @@ -15,9 +15,6 @@ * You should have received a copy of the GNU General Public License * along with this program. If not, see . */ -#define _DEFAULT_SOURCE -#define _BSD_SOURCE - #include "cg-base.h" #include @@ -41,7 +38,7 @@ const int64_t default_priority = 0; /** * The default class for the program */ -char* const default_class = PKGNAME "::cg-gamma::standard"; +char default_class[] = PKGNAME "::cg-gamma::standard"; @@ -218,7 +215,7 @@ static int parse_double(double* restrict out, const char* restrict str) char* end; errno = 0; *out = strtod(str, &end); - if (errno || (out < 0) || isinf(*out) || isnan(*out) || *end) + if (errno || (*out < 0) || isinf(*out) || isnan(*out) || *end) return -1; if (!strchr("0123456789.", *str)) return -1; @@ -432,6 +429,7 @@ int handle_args(int argc, char* argv[], char* method, char* site, free(fflag), fflag = NULL; errno = saved_errno; return cleanup(-1); + (void) site; } -- cgit v1.2.3-70-g09d2