aboutgitcodebugslistschat
path: root/pcap.c
diff options
context:
space:
mode:
Diffstat (limited to 'pcap.c')
-rw-r--r--pcap.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/pcap.c b/pcap.c
index e00fc45..9c617ce 100644
--- a/pcap.c
+++ b/pcap.c
@@ -167,9 +167,8 @@ fail:
/**
* pcap_init() - Initialise pcap file
* @c: Execution context
- * @index: pcap name index: passt instance number or pasta netns socket
*/
-void pcap_init(struct ctx *c, int index)
+void pcap_init(struct ctx *c)
{
struct timeval tv;
@@ -196,7 +195,7 @@ void pcap_init(struct ctx *c, int index)
snprintf(name + strlen(PCAP_PREFIX) + strlen(PCAP_ISO8601_STR),
sizeof(name) - strlen(PCAP_PREFIX) -
strlen(PCAP_ISO8601_STR),
- "_%i.pcap", index);
+ "_%i.pcap", getpid());
strncpy(c->pcap, name, PATH_MAX);
}