[libvirt] [PATCH] avoid using deprecated udev logging functions

Guido Günther agx at sigxcpu.org
Wed Dec 17 06:01:50 UTC 2014


On Tue, Dec 16, 2014 at 03:28:33PM -0700, Eric Blake wrote:
> On 12/16/2014 03:08 PM, Guido Günther wrote:
> > On Mon, Dec 15, 2014 at 03:33:13PM +0000, Daniel P. Berrange wrote:
> >> In systemd >= 218, the udev_set_log_fn method has been marked
> >> deprecated and turned into a no-op. Nothing in the udev client
> >> library will print to stderr by default anymore, so we can
> >> just stop installing a logging hook for new enough udev.
> > 
> > This looks somehow reversed. Why should we log for libudev < 218 if we
> > deem the messages superfluous for >= 218? I'm probably missing
> > something obvious. If not we should remove the messages completely to
> > be consitent.
> 
> If I understand correctly, the older udev _requires_ us to supply a
> logging alternative (because the default is noisy); the newer udev is
> silent by default and therefore deprecated the function used to install
> our logging alternative.  So the patch looked correct - for old
> versions, do what we have always done to stay quiet, for new versions,
> avoid the deprecated function and we stay quiet by default.

Yeah, rereading the code made it clear. Thanks for the clarification.
Cheers,
 -- Guido




More information about the libvir-list mailing list