This small patch extends the lib json_writer module for formerly
deactivated functionality.

Signed-off-by: Matthias Tafelmeier <matthias.tafelme...@gmx.net>
---
 include/json_writer.h | 1 +
 lib/json_writer.c     | 7 -------
 2 files changed, 1 insertion(+), 7 deletions(-)

diff --git a/include/json_writer.h b/include/json_writer.h
index ab9a008..3e2bbff 100644
--- a/include/json_writer.h
+++ b/include/json_writer.h
@@ -15,6 +15,7 @@
 #ifndef _JSON_WRITER_H_
 #define _JSON_WRITER_H_
 
+#include <stdio.h>
 #include <stdbool.h>
 #include <stdint.h>
 
diff --git a/lib/json_writer.c b/lib/json_writer.c
index 2af16e1..dfed4d7 100644
--- a/lib/json_writer.c
+++ b/lib/json_writer.c
@@ -12,7 +12,6 @@
  * Authors:    Stephen Hemminger <step...@networkplumber.org>
  */
 
-#include <stdio.h>
 #include <stdbool.h>
 #include <stdarg.h>
 #include <assert.h>
@@ -201,7 +200,6 @@ void jsonw_bool(json_writer_t *self, bool val)
        jsonw_printf(self, "%s", val ? "true" : "false");
 }
 
-#ifdef notused
 void jsonw_null(json_writer_t *self)
 {
        jsonw_printf(self, "null");
@@ -211,7 +209,6 @@ void jsonw_float(json_writer_t *self, double num)
 {
        jsonw_printf(self, "%g", num);
 }
-#endif
 
 void jsonw_uint(json_writer_t *self, uint64_t num)
 {
@@ -236,13 +233,11 @@ void jsonw_bool_field(json_writer_t *self, const char 
*prop, bool val)
        jsonw_bool(self, val);
 }
 
-#ifdef notused
 void jsonw_float_field(json_writer_t *self, const char *prop, double val)
 {
        jsonw_name(self, prop);
        jsonw_float(self, val);
 }
-#endif
 
 void jsonw_uint_field(json_writer_t *self, const char *prop, uint64_t num)
 {
@@ -256,13 +251,11 @@ void jsonw_int_field(json_writer_t *self, const char 
*prop, int64_t num)
        jsonw_int(self, num);
 }
 
-#ifdef notused
 void jsonw_null_field(json_writer_t *self, const char *prop)
 {
        jsonw_name(self, prop);
        jsonw_null(self);
 }
-#endif
 
 #ifdef TEST
 int main(int argc, char **argv)
-- 
1.9.1

--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to