Message ID | 20221109183204.33ae109d@rorschach.local.home (mailing list archive) |
---|---|
State | Accepted |
Commit | 3913018ea01eedea0eb9d98c6321553317b5d54a |
Headers | show |
Series | trace-cmd: Quiet gcc warning of snprintf truncation | expand |
diff --git a/tracecmd/trace-setup-guest.c b/tracecmd/trace-setup-guest.c index 899848cb254a..6b0a9fe8a5bc 100644 --- a/tracecmd/trace-setup-guest.c +++ b/tracecmd/trace-setup-guest.c @@ -121,7 +121,7 @@ static int attach_guest_fifos(const char *guest, int nr_cpus) " <target type='virtio' name='%s%d'/>\n" "</channel>"; char tmp_path[PATH_MAX], path[PATH_MAX]; - char cmd[PATH_MAX], xml[PATH_MAX]; + char cmd[PATH_MAX + 256], xml[PATH_MAX + 256]; int i, fd, ret = 0; strcpy(tmp_path, "/tmp/pipexmlXXXXXX");