summaryrefslogtreecommitdiff
path: root/trafgen.c
diff options
context:
space:
mode:
Diffstat (limited to 'trafgen.c')
-rw-r--r--trafgen.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/trafgen.c b/trafgen.c
index a845783..d01f160 100644
--- a/trafgen.c
+++ b/trafgen.c
@@ -556,8 +556,6 @@ static void xmit_slowpath_or_die(struct ctx *ctx, unsigned int cpu, unsigned lon
drop_privileges(ctx->enforce, ctx->uid, ctx->gid);
- preprocess_packets();
-
bug_on(gettimeofday(&start, NULL));
while (likely(sigint == 0 && num > 0 && plen > 0)) {
@@ -647,8 +645,6 @@ static void xmit_fastpath_or_die(struct ctx *ctx, unsigned int cpu, unsigned lon
if (ctx->num == 0 && orig_num > 0)
num = 0;
- preprocess_packets();
-
bug_on(gettimeofday(&start, NULL));
while (likely(sigint == 0 && num > 0 && plen > 0)) {
@@ -834,6 +830,8 @@ static void main_loop(struct ctx *ctx, char *confname, bool slow,
else
compile_packets(confname, ctx->verbose, cpu, invoke_cpp);
+ preprocess_packets();
+
xmit_packet_precheck(ctx, cpu);
if (cpu == 0) {