Skip to content

Commit 41ba27c

Browse files
committed
Use __func__ from C99 in an error message
1 parent 33040b7 commit 41ba27c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tcpdump.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3285,7 +3285,7 @@ dump_packet_and_trunc(u_char *user, const struct pcap_pkthdr *h, const u_char *s
32853285
/* Allocate space for max filename + \0. */
32863286
dump_info->CurrentFileName = (char *)malloc(PATH_MAX + 1);
32873287
if (dump_info->CurrentFileName == NULL)
3288-
error("dump_packet_and_trunc: malloc");
3288+
error("%s: malloc", __func__);
32893289
/*
32903290
* Gflag was set otherwise we wouldn't be here. Reset the count
32913291
* so multiple files would end with 1,2,3 in the filename.

0 commit comments

Comments
 (0)