swima-collector: Use proper type for field precision
authorTobias Brunner <tobias@strongswan.org>
Tue, 7 May 2019 12:40:58 +0000 (14:40 +0200)
committerTobias Brunner <tobias@strongswan.org>
Wed, 8 May 2019 12:48:54 +0000 (14:48 +0200)
src/libimcv/swima/swima_collector.c

index d2b5061..e8117eb 100644 (file)
@@ -437,7 +437,8 @@ static bool collect_tags(private_swima_collector_t *this, char *pathname,
 
                sw_locator = chunk_empty;
                pos = strstr(pathname, "/swidtag");
-               if (pos && asprintf(&uri, "file://%.*s", pos - pathname, pathname) > 0)
+               if (pos &&
+                       asprintf(&uri, "file://%.*s", (int)(pos - pathname), pathname) > 0)
                {
                        sw_locator = chunk_from_str(uri);
                }