audit-util: check correct errno

This commit is contained in:
Mike Yuan
2024-09-04 18:50:54 +02:00
parent 6f0d6ef7ce
commit 190a095380
+1 -1
View File
@@ -99,7 +99,7 @@ static int try_audit_request(int fd) {
n = recvmsg_safe(fd, &mh, 0);
if (n < 0)
return -errno;
return n;
if (n != NLMSG_LENGTH(sizeof(struct nlmsgerr)))
return -EIO;