mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2024-12-22 21:55:25 +00:00
logging: avoid variables called 'daemon' due to function clash
With some versions of GLibC / GCC, a variable called 'daemon' will result in a warning about clashing with the function also named 'daemon'. Rename it to 'dmn' to avoid the clash. Signed-off-by: Daniel P. Berrange <berrange@redhat.com>
This commit is contained in:
parent
35b2a2d99a
commit
753346c5dd
@ -127,12 +127,12 @@ virLogDaemonFree(virLogDaemonPtr logd)
|
||||
static void
|
||||
virLogDaemonInhibitor(bool inhibit, void *opaque)
|
||||
{
|
||||
virLogDaemonPtr daemon = opaque;
|
||||
virLogDaemonPtr dmn = opaque;
|
||||
|
||||
if (inhibit)
|
||||
virNetDaemonAddShutdownInhibition(daemon->dmn);
|
||||
virNetDaemonAddShutdownInhibition(dmn->dmn);
|
||||
else
|
||||
virNetDaemonRemoveShutdownInhibition(daemon->dmn);
|
||||
virNetDaemonRemoveShutdownInhibition(dmn->dmn);
|
||||
}
|
||||
|
||||
static virLogDaemonPtr
|
||||
@ -177,9 +177,9 @@ virLogDaemonNew(virLogDaemonConfigPtr config, bool privileged)
|
||||
|
||||
|
||||
virLogHandlerPtr
|
||||
virLogDaemonGetHandler(virLogDaemonPtr daemon)
|
||||
virLogDaemonGetHandler(virLogDaemonPtr dmn)
|
||||
{
|
||||
return daemon->handler;
|
||||
return dmn->handler;
|
||||
}
|
||||
|
||||
|
||||
|
@ -40,6 +40,6 @@ struct _virLogDaemonClient {
|
||||
|
||||
extern virLogDaemonPtr logDaemon;
|
||||
|
||||
virLogHandlerPtr virLogDaemonGetHandler(virLogDaemonPtr daemon);
|
||||
virLogHandlerPtr virLogDaemonGetHandler(virLogDaemonPtr dmn);
|
||||
|
||||
#endif /* __VIR_LOG_DAEMON_H__ */
|
||||
|
Loading…
Reference in New Issue
Block a user