diff options
author | Phil <phil.buschmann@tum.de> | 2018-08-01 03:26:50 +0200 |
---|---|---|
committer | Phil <phil.buschmann@tum.de> | 2018-08-01 03:26:50 +0200 |
commit | 83095b7bbf49263d66ab1d89d0535e8fee2a9d01 (patch) | |
tree | 383223e348d4d6ad27b512718a1c5b7b48e3c731 /src/json/json_gnsrecord.c | |
parent | 7d1449573337751de58055d89c954e0c4ebbe6f4 (diff) | |
download | gnunet-83095b7bbf49263d66ab1d89d0535e8fee2a9d01.tar.gz gnunet-83095b7bbf49263d66ab1d89d0535e8fee2a9d01.zip |
-fix json and namestore
Diffstat (limited to 'src/json/json_gnsrecord.c')
-rw-r--r-- | src/json/json_gnsrecord.c | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/src/json/json_gnsrecord.c b/src/json/json_gnsrecord.c index 48b78f38b..4f6d30748 100644 --- a/src/json/json_gnsrecord.c +++ b/src/json/json_gnsrecord.c | |||
@@ -23,7 +23,6 @@ | |||
23 | */ | 23 | */ |
24 | #include "platform.h" | 24 | #include "platform.h" |
25 | #include "gnunet_util_lib.h" | 25 | #include "gnunet_util_lib.h" |
26 | #include "gnunet_gnsrecord_lib.h" | ||
27 | #include "gnunet_json_lib.h" | 26 | #include "gnunet_json_lib.h" |
28 | 27 | ||
29 | #define GNUNET_JSON_GNSRECORD_VALUE "value" | 28 | #define GNUNET_JSON_GNSRECORD_VALUE "value" |
@@ -111,7 +110,16 @@ parse_gnsrecordobject (void *cls, | |||
111 | } | 110 | } |
112 | else | 111 | else |
113 | { | 112 | { |
114 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Value invalid for expiration time"); | 113 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Expiration time invalid"); |
114 | return GNUNET_SYSERR; | ||
115 | } | ||
116 | // check if flag is a valid enum value | ||
117 | if ((GNUNET_GNSRECORD_RF_NONE != flag) | ||
118 | && (GNUNET_GNSRECORD_RF_PRIVATE != flag) | ||
119 | && (GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION != flag) | ||
120 | && (GNUNET_GNSRECORD_RF_SHADOW_RECORD) != flag) | ||
121 | { | ||
122 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Flag invalid"); | ||
115 | return GNUNET_SYSERR; | 123 | return GNUNET_SYSERR; |
116 | } | 124 | } |
117 | gnsrecord_object->flags = (enum GNUNET_GNSRECORD_Flags)flag; | 125 | gnsrecord_object->flags = (enum GNUNET_GNSRECORD_Flags)flag; |