summaryrefslogtreecommitdiff
path: root/ais_json.c
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2014-08-23 15:22:49 -0400
committerEric S. Raymond <esr@thyrsus.com>2014-08-23 15:22:49 -0400
commit3f51a3473aeeecf668bff11739e2e2ea45544f6b (patch)
tree3501cfb7ec6aefd9a4e74b3cc3dfd4574e5ab1ec /ais_json.c
parente7cc65587ab1adbd73f1d4d086914e1d7f39d4a3 (diff)
downloadgpsd-3f51a3473aeeecf668bff11739e2e2ea45544f6b.tar.gz
Full implementation of AIS 'structured' bit. All regression tests pass.
Diffstat (limited to 'ais_json.c')
-rw-r--r--ais_json.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/ais_json.c b/ais_json.c
index 4d31ba87..be1ce19c 100644
--- a/ais_json.c
+++ b/ais_json.c
@@ -268,6 +268,7 @@ int json_ais_read(const char *buf,
lenhex_unpack(data, &ais->type6.bitcount,
ais->type6.bitdata, sizeof(ais->type6.bitdata));
}
+ ais->type6.structured = structured;
} else if (strstr(buf, "\"type\":7,") != NULL
|| strstr(buf, "\"type\":13,") != NULL) {
status = json_read_object(buf, json_ais7, endptr);
@@ -413,6 +414,7 @@ int json_ais_read(const char *buf,
lenhex_unpack(data, &ais->type8.bitcount,
ais->type8.bitdata, sizeof(ais->type8.bitdata));
}
+ ais->type8.structured = structured;
} else if (strstr(buf, "\"type\":9,") != NULL) {
status = json_read_object(buf, json_ais9, endptr);
} else if (strstr(buf, "\"type\":10,") != NULL) {