diff options
author | Guy Harris <gharris@sonic.net> | 2021-04-30 03:18:25 -0700 |
---|---|---|
committer | Guy Harris <gharris@sonic.net> | 2021-04-30 03:19:19 -0700 |
commit | 57a1514ac74527651ad42dca3041f3f53509317e (patch) | |
tree | a69a01eaeac3d625a5312930fa81f0a3c6b12e96 /epan/dissectors/packet-nbt.c | |
parent | 09147397007c5456fd5acd4794b5ba15330bdad3 (diff) | |
download | wireshark-57a1514ac74527651ad42dca3041f3f53509317e.tar.gz wireshark-57a1514ac74527651ad42dca3041f3f53509317e.tar.bz2 wireshark-57a1514ac74527651ad42dca3041f3f53509317e.zip |
Cast away the return value of g_strlcpy() and g_strlcat().
Most of the time, the return value tells us nothing useful, as we've
already decided that we're perfectly willing to live with string
truncation. Hopefully this keeps Coverity from whining that those
routines could return an error code (NARRATOR: They don't) and thus that
we're ignoring the possibility of failure (as indicated, we've already
decided that we can live with string truncation, so truncation is *NOT*
a failure).
Diffstat (limited to 'epan/dissectors/packet-nbt.c')
-rw-r--r-- | epan/dissectors/packet-nbt.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/epan/dissectors/packet-nbt.c b/epan/dissectors/packet-nbt.c index 176e88170d..4b51144376 100644 --- a/epan/dissectors/packet-nbt.c +++ b/epan/dissectors/packet-nbt.c @@ -654,9 +654,9 @@ dissect_nbns_answer(tvbuff_t *tvb, packet_info *pinfo, int offset, int nbns_data (cur_offset - offset) + data_len, ett_nbns_rr, NULL, "%s: type %s, class %s", name, type_name, class_name); - g_strlcat(name, " (", MAX_NAME_LEN); - g_strlcat(name, netbios_name_type_descr(name_type), MAX_NAME_LEN); - g_strlcat(name, ")", MAX_NAME_LEN); + (void) g_strlcat(name, " (", MAX_NAME_LEN); + (void) g_strlcat(name, netbios_name_type_descr(name_type), MAX_NAME_LEN); + (void) g_strlcat(name, ")", MAX_NAME_LEN); add_rr_to_tree(rr_tree, tvb, offset, name, name_len, type, dns_class, ttl, data_len); } |