[Libreoffice-bugs] [Bug 46390] EasyHack: Move VERBOSE to OSL_DEBUG_LEVEL

bugzilla-daemon at freedesktop.org bugzilla-daemon at freedesktop.org
Tue Feb 21 05:35:35 PST 2012


https://bugs.freedesktop.org/show_bug.cgi?id=46390

Stephan Bergmann <sbergman at redhat.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |sbergman at redhat.com

--- Comment #1 from Stephan Bergmann <sbergman at redhat.com> 2012-02-21 05:35:35 PST ---
Or even better yet, replace code like

#if VERBOSE
  fprintf(stderr, ...)
#endif

or

#if OSL_DEBUG_LEVEL > 2
  fprintf(stderr, ...)
#endif

etc. with

  SAL_INFO("your.special.area", ...);

where "your.special.area" is a token that allows to enable logging of just that
extra information, with SAL_LOG=+WARN+INFO.your.special.area environment
variable (and for the basegfx example might for example be "basegfx.verbose"). 
See sal/inc/sal/log.hxx and sal/inc/sal/log-areas.dox.

-- 
Configure bugmail: https://bugs.freedesktop.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.


More information about the Libreoffice-bugs mailing list