summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorAndreas Schneider <asn@samba.org>2018-11-07 14:32:29 +0100
committerKarolin Seeger <kseeger@samba.org>2018-11-12 18:01:17 +0100
commite3e037c6f13c1c9039265a5776de97cce99d5418 (patch)
treeeabc5cdeeffdde108130dd9c6c249b5088f3bca6 /lib
parent092982982004d44b97ae5c1b29209ef0a972c8fe (diff)
downloadsamba-e3e037c6f13c1c9039265a5776de97cce99d5418.tar.gz
lib:util: Fix DEBUGCLASS pointer initializiation
This fixes a segfault in pyglue: ==10142== Process terminating with default action of signal 11 (SIGSEGV) ==10142== Bad permissions for mapped region at address 0x6F00A20 ==10142== at 0x6F1074B: py_set_debug_level (pyglue.c:165) BUG: https://bugzilla.samba.org/show_bug.cgi?id=13679 Signed-off-by: Andreas Schneider <asn@samba.org> Reviewed-by: Jeremy Allison <jra@samba.org> (cherry picked from commit 71ef09c1afdbf967b829cb66b33c3a5cb1c18ba0) Autobuild-User(v4-8-test): Karolin Seeger <kseeger@samba.org> Autobuild-Date(v4-8-test): Mon Nov 12 18:01:17 CET 2018 on sn-devel-144
Diffstat (limited to 'lib')
-rw-r--r--lib/util/debug.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/util/debug.c b/lib/util/debug.c
index 022e37b36c7..1a61164c064 100644
--- a/lib/util/debug.c
+++ b/lib/util/debug.c
@@ -549,10 +549,10 @@ static const char *default_classname_table[] = {
* This is to allow reading of DEBUGLEVEL_CLASS before the debug
* system has been initialized.
*/
-static const int debug_class_list_initial[ARRAY_SIZE(default_classname_table)];
+static int debug_class_list_initial[ARRAY_SIZE(default_classname_table)];
static size_t debug_num_classes = 0;
-int *DEBUGLEVEL_CLASS = discard_const_p(int, debug_class_list_initial);
+int *DEBUGLEVEL_CLASS = debug_class_list_initial;
/* -------------------------------------------------------------------------- **