Re: [libvirt] [PATCH] cleanup of loging definitions

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Nov 06, 2008 at 02:17:49PM +0000, Daniel P. Berrange wrote:
> On Thu, Nov 06, 2008 at 02:16:52PM +0100, Daniel Veillard wrote:
> >   Currently the debugFlag switch, the VIR_DEBUG, DEBUG and DEBUG0
> > macros were scattered in various places, duplicated once (or twice)
> > per generated binaries. This patch moves everything in one virtlog.h
> > header, one virtlog.c file and set up the makefiles so that the
> > various binaries refers to the same bits.
> >   That's a cleanup with no functional change to prepare the real
> > loging APIs, patch and the 2 new files attached,
> 
> ACK, this seems like a good idea considering we'll have more logging
> stuff in the future. I'd prefer to drop the 'virt' prefix though and
> just call it 'logging.c' or 'log.c'

Okay, I don't really care for the name, except I was wondering about log.h
and since we prefer to align .c and .h names ...

wei:~/libvirt/src -> locate /log.h | wc -l
14

 okay most of them come from kernel source headers, but things like
  /usr/include/avahi-core/log.h
make me feel that a virt prefix is safer ...

> Perhaps we should have a virLogInitialize() method todo the stuff
> like getenv("LIBVIRT_DEBUG") that's currently in virInitialize().
> eg, just make virInitialize() call virLogInitialize() for setup

  Yup, that's one of the things to do, it's just an initial refactoring
to ease doing the cleanup and extensions.

Daniel

-- 
Daniel Veillard      | libxml Gnome XML XSLT toolkit  http://xmlsoft.org/
daniel@xxxxxxxxxxxx  | Rpmfind RPM search engine http://rpmfind.net/
http://veillard.com/ | virtualization library  http://libvirt.org/

--
Libvir-list mailing list
Libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list

[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]