virhostcpu: Fix non-Linux virHostCPUGetPhysAddrSize() stub

The non-Linux version of virHostCPUGetPhysAddrSize() is lacking
G_GNUC_UNUSED attribute to its @size argument which triggers an
error on all non-Linux builds. And while at it, make the function
actually signal error (ENOSYS) since it does not set the
argument.

Signed-off-by: Michal Privoznik <mprivozn@redhat.com>
This commit is contained in:
Michal Privoznik 2022-08-04 10:27:56 +02:00
parent 1c1a7cdd40
commit 155416ed77

View File

@ -1672,9 +1672,10 @@ virHostCPUGetSignature(char **signature)
}
int
virHostCPUGetPhysAddrSize(unsigned int *size)
virHostCPUGetPhysAddrSize(unsigned int *size G_GNUC_UNUSED)
{
return 0;
errno = ENOSYS;
return -1;
}
#endif /* __linux__ */