diff --git a/tools/xfsslower.py b/tools/xfsslower.py index ef79a8947cb8..ef4b6b5b01fc 100755 --- a/tools/xfsslower.py +++ b/tools/xfsslower.py @@ -186,8 +186,11 @@ // populate output struct u32 size = PT_REGS_RC(ctx); - struct data_t data = {.type = type, .size = size, .delta_us = delta_us, - .pid = pid}; + struct data_t data = {}; + data.type = type; + data.size = size; + data.delta_us = delta_us; + data.pid = pid; data.ts_us = ts / 1000; data.offset = valp->offset; bpf_get_current_comm(&data.task, sizeof(data.task));