[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[gpsd-dev] [PATCH] Ensure all functions of the client API are available

From: Robert Norris
Subject: [gpsd-dev] [PATCH] Ensure all functions of the client API are available at all times.
Date: Sat, 30 Jul 2016 18:08:50 +0000

Thus client programs won't fail to build or run due to missing functions.
Although when clientdebug is turned off in building libgps, then these 
functions won't do anything.
 libgps_core.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/libgps_core.c b/libgps_core.c
index 582e210..ca580bd 100644
--- a/libgps_core.c
+++ b/libgps_core.c
@@ -49,6 +49,10 @@ void libgps_trace(int errlevel, const char *fmt, ...)
        (void)fputs(buf, debugfp);
+// Functions defined as so to furfil the API but otherwise do nothing when 
built with debug capability turned off
+void gps_enable_debug(int level UNUSED, FILE * fp UNUSED) {}
+void libgps_trace(int errlevel UNUSED, const char *fmt UNUSED, ...){}
 #endif /* LIBGPS_DEBUG */

reply via email to

[Prev in Thread] Current Thread [Next in Thread]