summaryrefslogtreecommitdiff
path: root/src/print.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/print.c')
-rw-r--r--src/print.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/src/print.c b/src/print.c
index e56d213..13e53d9 100644
--- a/src/print.c
+++ b/src/print.c
@@ -57,11 +57,8 @@ void print_item(struct json *json, char **str, int64_t *size, int64_t *index) {
case JSON_NUMBER:
append_printf(str, size, index, "%lf", json->num);
break;
- case JSON_TRUE:
- append_printf(str, size, index, "true");
- break;
- case JSON_FALSE:
- append_printf(str, size, index, "false");
+ case JSON_BOOL:
+ append_printf(str, size, index, json->boolean ? "true" : "false");
break;
case JSON_NULL:
append_printf(str, size, index, "null");
@@ -98,8 +95,6 @@ void print_item(struct json *json, char **str, int64_t *size, int64_t *index) {
}
append_printf(str, size, index, "\"");
break;
- case JSON_INVALID:
- break;
}
}