Radish alpha
H
HardenedBSD Package Manager
Radicle
Git (anonymous pull)
Log in to clone via SSH
Use UCL_COUNT to return the number of elements of an ucl_object as it return 0 if the object is NULL
Baptiste Daroussin committed 12 years ago
commit 8cfe46ab69165903fe692e246a50caf276a9e78b
parent 2addf978bf6c4c2b78d17cb11c6d782e10158267
1 file changed +2 -1
modified libpkg/pkg_object.c
@@ -27,6 +27,7 @@
#include <assert.h>
#include <ucl.h>
#include "pkg.h"
+
#include "private/pkg.h"

const char *
pkg_object_dump(pkg_object *o)
@@ -106,5 +107,5 @@ pkg_object_int(pkg_object *o)
unsigned
pkg_object_count(pkg_object *o)
{
-
	return (o->len);
+
	return (UCL_COUNT(o));
}