aboutsummaryrefslogtreecommitdiffstats
path: root/executor
diff options
context:
space:
mode:
Diffstat (limited to 'executor')
-rw-r--r--executor/executor.cc13
1 files changed, 6 insertions, 7 deletions
diff --git a/executor/executor.cc b/executor/executor.cc
index 35fa27c47..02971f374 100644
--- a/executor/executor.cc
+++ b/executor/executor.cc
@@ -808,6 +808,12 @@ void realloc_output_data()
void execute_one()
{
in_execute_one = true;
+#if GOOS_linux
+ char buf[64];
+ // Linux TASK_COMM_LEN is only 16, so the name needs to be compact.
+ snprintf(buf, sizeof(buf), "syz.%llu.%llu", procid, request_id);
+ prctl(PR_SET_NAME, buf);
+#endif
if (flag_snapshot)
SnapshotStart();
else
@@ -816,13 +822,6 @@ void execute_one()
uint64 start = current_time_ms();
uint8* input_pos = input_data;
-#if GOOS_linux
- char buf[64];
- // Linux TASK_COMM_LEN is only 16, so the name needs to be compact.
- snprintf(buf, sizeof(buf), "syz.%llu.%llu", procid, request_id);
- prctl(PR_SET_NAME, buf);
-#endif
-
if (cover_collection_required()) {
if (!flag_threaded)
cover_enable(&threads[0].cov, flag_comparisons, false);