mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-10 23:45:53 -06:00
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>
This commit is contained in:
parent
b4861ce976
commit
1398b70044
@ -1,5 +1,5 @@
|
||||
/*
|
||||
* viraccessdriverpolkit.c: polkited access control driver
|
||||
* viraccessdriverpolkit.c: polkitd access control driver
|
||||
*
|
||||
* Copyright (C) 2012, 2014 Red Hat, Inc.
|
||||
*
|
||||
@ -134,8 +134,8 @@ virAccessDriverPolkitCheck(virAccessManagerPtr manager ATTRIBUTE_UNUSED,
|
||||
&uid) < 0)
|
||||
goto cleanup;
|
||||
|
||||
VIR_DEBUG("Check action '%s' for process '%d' time %lld uid %d",
|
||||
actionid, pid, startTime, uid);
|
||||
VIR_DEBUG("Check action '%s' for process '%lld' time %lld uid %d",
|
||||
actionid, (long long) pid, startTime, uid);
|
||||
|
||||
rv = virPolkitCheckAuth(actionid,
|
||||
pid,
|
||||
|
Loading…
Reference in New Issue
Block a user