diff --git a/src/util/virperf.c b/src/util/virperf.c index 9dc4e2562f..359a9c34ea 100644 --- a/src/util/virperf.c +++ b/src/util/virperf.c @@ -247,7 +247,7 @@ virPerfReadEvent(virPerfPtr perf, if (event == NULL || !event->enabled) return -1; - if (read(event->fd, value, sizeof(uint64_t)) < 0) { + if (saferead(event->fd, value, sizeof(uint64_t)) < 0) { virReportSystemError(errno, "%s", _("Unable to read cache data")); return -1;