summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Golle2020-08-31 09:55:09 +0000
committerDaniel Golle2020-08-31 09:55:09 +0000
commitcf44c2feb606b60ba3f35392e102c281ef6ea0da (patch)
tree1c2ce20f04684840cd22a05137ea3efe382fc8c5
parent4318ab1de6881f00ccb3a04c755893dee5f068ed (diff)
downloadopkg-lede-cf44c2feb606b60ba3f35392e102c281ef6ea0da.tar.gz
libopkg: fix compiler warning
libopkg/pkg.c: In function 'pkg_set_raw': libopkg/pkg.c:109:58: warning: format '%d' expects argument of type 'int', but argument 5 has type 'size_t' {aka 'long unsigned int'} [-Wformat=] Use '%zu' instead. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
-rw-r--r--libopkg/pkg.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/libopkg/pkg.c b/libopkg/pkg.c
index e5bfe6f..f68ce0c 100644
--- a/libopkg/pkg.c
+++ b/libopkg/pkg.c
@@ -106,7 +106,7 @@ void *pkg_set_raw(pkg_t *pkg, int id, const void *val, size_t len)
blob_for_each_attr(cur, pkg->blob.head, rem) {
if (blob_id(cur) == id) {
if (blob_len(cur) < len) {
- fprintf(stderr, "ERROR: truncating field %d <%p> to %d byte",
+ fprintf(stderr, "ERROR: truncating field %d <%p> to %zu byte",
id, val, blob_len(cur));
}
memcpy(blob_data(cur), val, blob_len(cur));