]> git.ipfire.org Git - thirdparty/libvirt.git/commit
build: fix mingw printing of pid
authorEric Blake <eblake@redhat.com>
Mon, 8 Dec 2014 21:56:31 +0000 (14:56 -0700)
committerEric Blake <eblake@redhat.com>
Mon, 8 Dec 2014 22:01:24 +0000 (15:01 -0700)
commit1398b70044bde2c6b9e48b64fc532f830f57fec3
treecb962163b37cef8f2cdcc1c423c3031582fa1c01
parentb4861ce9766674fcd8e90488c56bd063fb935c1f
build: fix mingw printing of pid

Commit c75425734 introduced a compilation failure:

../../src/access/viraccessdriverpolkit.c: In function 'virAccessDriverPolkitCheck':
../../src/access/viraccessdriverpolkit.c:137:5: error: format '%d' expects argument of type 'int', but argument 9 has type 'pid_t' [-Werror=format=]
     VIR_DEBUG("Check action '%s' for process '%d' time %lld uid %d",
     ^

Since mingw pid_t is 64 bits, it's easier to just follow what we've
done elsewhere and cast to a large enough type when printing pids.

* src/access/viraccessdriverpolkit.c (virAccessDriverPolkitCheck):
Add cast.

Signed-off-by: Eric Blake <eblake@redhat.com>
src/access/viraccessdriverpolkit.c