]> git.ipfire.org Git - thirdparty/asterisk.git/commit
core/logging: Fix broken syslog levels on older glibc. 52/2452/3
authorWalter Doekes <walter+asterisk@wjd.nu>
Thu, 24 Mar 2016 10:38:16 +0000 (11:38 +0100)
committerJoshua Colp <jcolp@digium.com>
Thu, 24 Mar 2016 11:34:20 +0000 (06:34 -0500)
commit82e55e48835b3f71aa88c439ab406266b494d4f8
tree16fa64e2470d0031ee17eb44b4080c73466bc807
parentc5170677e72e48b487462e79a31974845a417dce
core/logging: Fix broken syslog levels on older glibc.

The fix to ASTERISK-25407 introduced the usage of LOG_MAKEPRI. However
this macro is broken in older glibc (< 2.17); it would left-shift the
facility a second time, causing the resultant priority to become
invalid.

The syslog manpage mentions nothing about LOG_MAKEPRI and suggests this:

    The priority argument is formed by ORing the facility and the level
    values [...].

ASTERISK-25510 #close
Reported by: Michael Newton

Change-Id: Ia89debe7fac5ad090c7ef595c0707f31bb1e3d03
main/logger.c