libosmocore/tests/logging
Neels Hofmeyr a280b82f8e show bug in logging: erratic redirection to DLGLOBAL for first invalid category
Add a check to logging_test.c to show a bug: when a logging category value that
is the first out-of-bounds value is passed to the logging system, the internal
map_subsys() fails to redirect to DLGLOBAL due to a flawed conditional. This
results in a too large array index and undefined behavior. A sanitize build
should catch this.

The bug is confirmed by the fact that logging_test.err stays the same
(hopefully) although a logging output should appear from this patch. The test
could as well segfault or anything else, it's a bit of a gamble.

This bug will be fixed along with the expectation in a subsequent patch.

Change-Id: I12bf38b6c1f85e2d7bf5a15f942dfe0beed41eba
2016-12-12 15:47:51 +01:00
..
logging_test.c show bug in logging: erratic redirection to DLGLOBAL for first invalid category 2016-12-12 15:47:51 +01:00
logging_test.err fix logging: redirection to DLGLOBAL for invalid categories 2016-12-12 15:47:37 +01:00
logging_test.ok logging: Move the logging test from OpenBSC into libosmocore 2012-09-27 16:29:54 +02:00