From ba0d080d3d9d7c0bdb5f00ed9f5a11fccf2d01d3 Mon Sep 17 00:00:00 2001 From: Chilledheart Date: Sun, 29 Jun 2014 12:57:41 +0800 Subject: [PATCH] [lib] cleanup some compiler warnings - lib/searpc-client.c:353:1: warning: control reaches end of non-void function [-Wreturn-type] - lib/searpc-utils.c:93:13: warning: enumeration value 'JSON_ARRAY' not handled in switch [-Wswitch] --- lib/searpc-client.c | 2 ++ lib/searpc-utils.c | 6 ++++++ 2 files changed, 8 insertions(+) diff --git a/lib/searpc-client.c b/lib/searpc-client.c index dc7784f..4ca2d06 100644 --- a/lib/searpc-client.c +++ b/lib/searpc-client.c @@ -350,6 +350,8 @@ searpc_client_generic_callback (char *retstr, size_t len, } } g_free (data); + + return 0; } diff --git a/lib/searpc-utils.c b/lib/searpc-utils.c index de21d2c..08c00d8 100644 --- a/lib/searpc-utils.c +++ b/lib/searpc-utils.c @@ -172,6 +172,12 @@ static gboolean json_deserialize_pspec (GValue *value, GParamSpec *pspec, json_t g_value_set_object (value, NULL); return TRUE; } + break; + case JSON_ARRAY: + return FALSE; + break; + default: + return FALSE; } return FALSE;