summaryrefslogtreecommitdiffstats
path: root/plugins/ommongodb/ommongodb.c
diff options
context:
space:
mode:
authorRainer Gerhards <rgerhards@adiscon.com>2013-10-26 16:03:27 +0200
committerRainer Gerhards <rgerhards@adiscon.com>2013-10-26 16:03:27 +0200
commitdc4db17f51cc6d88af10a6155292ea53180a8e66 (patch)
treeae1a007713ed2bace76e4560bf20adbb84be4c73 /plugins/ommongodb/ommongodb.c
parentefa8dfb47da3ea46f06ab561aeb82ef1d6c3ee93 (diff)
parent620d0448171378748495f495b6db7b67686cdf49 (diff)
downloadrsyslog-dc4db17f51cc6d88af10a6155292ea53180a8e66.tar.gz
rsyslog-dc4db17f51cc6d88af10a6155292ea53180a8e66.tar.bz2
rsyslog-dc4db17f51cc6d88af10a6155292ea53180a8e66.zip
Merge branch 'master-var-refactor' into master-ruleeng
Diffstat (limited to 'plugins/ommongodb/ommongodb.c')
-rw-r--r--plugins/ommongodb/ommongodb.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/plugins/ommongodb/ommongodb.c b/plugins/ommongodb/ommongodb.c
index 78781c08..af1f5a37 100644
--- a/plugins/ommongodb/ommongodb.c
+++ b/plugins/ommongodb/ommongodb.c
@@ -317,8 +317,11 @@ BSONAppendJSONObject(bson *doc, const gchar *name, struct json_object *json)
case json_type_int: {
int64_t i;
- /* FIXME: the future version will have get_int64 */
+#ifdef HAVE_JSON_OBJECT_NEW_INT64
+ i = json_object_get_int64(json);
+#else /* HAVE_JSON_OBJECT_NEW_INT64 */
i = json_object_get_int(json);
+#endif /* HAVE_JSON_OBJECT_NEW_INT64 */
if (i >= INT32_MIN && i <= INT32_MAX)
return bson_append_int32(doc, name, i);
else