From: Arran Cudbard-Bell Date: Wed, 20 Jan 2021 16:23:54 +0000 (+0000) Subject: Fix bad field access in json_object_from_value_box, and encode size X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=040d5690fe7260a214b44a7288e06f8eb96aef41;p=thirdparty%2Ffreeradius-server.git Fix bad field access in json_object_from_value_box, and encode size --- diff --git a/src/lib/json/json.c b/src/lib/json/json.c index 550971eb815..c2949b1bea9 100644 --- a/src/lib/json/json.c +++ b/src/lib/json/json.c @@ -241,7 +241,10 @@ json_object *json_object_from_value_box(TALLOC_CTX *ctx, fr_value_box_t const *d #ifdef HAVE_JSON_OBJECT_GET_INT64 case FR_TYPE_INT64: - return json_object_new_int64(data->vb_int16); + return json_object_new_int64(data->vb_int64); + + case FR_TYPE_SIZE: + return json_object_new_int64(data->vb_size); #endif } }