libimcv: Cast chunk length to int when printing as string
This commit is contained in:
@@ -301,7 +301,8 @@ METHOD(imv_swid_state_t, set_swid_inventory, void,
|
|||||||
tag_creator = tag_id->get_tag_creator(tag_id);
|
tag_creator = tag_id->get_tag_creator(tag_id);
|
||||||
sw_id = tag_id->get_unique_sw_id(tag_id, NULL);
|
sw_id = tag_id->get_unique_sw_id(tag_id, NULL);
|
||||||
snprintf(software_id, BUF_LEN, "%.*s__%.*s",
|
snprintf(software_id, BUF_LEN, "%.*s__%.*s",
|
||||||
tag_creator.len, tag_creator.ptr, sw_id.len, sw_id.ptr);
|
(int)tag_creator.len, tag_creator.ptr,
|
||||||
|
(int)sw_id.len, sw_id.ptr);
|
||||||
DBG3(DBG_IMV, " %s", software_id);
|
DBG3(DBG_IMV, " %s", software_id);
|
||||||
|
|
||||||
/* Add software ID to JSON array */
|
/* Add software ID to JSON array */
|
||||||
|
|||||||
@@ -125,7 +125,8 @@ static status_t generate_tags(private_swid_inventory_t *this,
|
|||||||
tag_creator = tag_id->get_tag_creator(tag_id);
|
tag_creator = tag_id->get_tag_creator(tag_id);
|
||||||
sw_id = tag_id->get_unique_sw_id(tag_id, NULL);
|
sw_id = tag_id->get_unique_sw_id(tag_id, NULL);
|
||||||
snprintf(software_id, BUF_LEN, "%.*s__%.*s",
|
snprintf(software_id, BUF_LEN, "%.*s__%.*s",
|
||||||
tag_creator.len, tag_creator.ptr, sw_id.len, sw_id.ptr);
|
(int)tag_creator.len, tag_creator.ptr,
|
||||||
|
(int)sw_id.len, sw_id.ptr);
|
||||||
|
|
||||||
swid_tag = swid_gen->generate_tag(swid_gen, software_id, NULL, NULL,
|
swid_tag = swid_gen->generate_tag(swid_gen, software_id, NULL, NULL,
|
||||||
full, pretty);
|
full, pretty);
|
||||||
|
|||||||
Reference in New Issue
Block a user