aboutsummaryrefslogtreecommitdiffstats
path: root/configure.in
diff options
context:
space:
mode:
authorHolger Hans Peter Freyther <zecke@selfish.org>2010-08-06 06:48:43 +0800
committerHolger Hans Peter Freyther <zecke@selfish.org>2010-08-06 06:50:23 +0800
commit43558316bc4e6ddac92dd198b07a4803c21dc77b (patch)
treeabc157bc9668a4859e1b9f0c64caf507af16562b /configure.in
parentc2b7f92a6c1ae3ad4f4865f3c2c69d4a3a5a279a (diff)
bsc_fd: Add a build option to be able to debug fd list corruption
bsc_register_fd on an already registered fd can corrupt the list in a heavy way and make the select end in an infinite loop, this code will workaround the issue and provide a way to set a breakpoint at the right position in the code.
Diffstat (limited to 'configure.in')
-rw-r--r--configure.in11
1 files changed, 11 insertions, 0 deletions
diff --git a/configure.in b/configure.in
index c3e00610..1684aaa3 100644
--- a/configure.in
+++ b/configure.in
@@ -77,6 +77,17 @@ then
AC_DEFINE([PANIC_INFLOOP],[1],[Use infinite loop on panic rather than fprintf/abort])
fi
+AC_ARG_ENABLE(bsc_fd_check,
+ [AS_HELP_STRING(
+ [--enable-bsc-fd-check],
+ [Instrument bsc_register_fd to check that the fd is registered]
+ )],
+ [fd_check=1], [fd_check=0])
+if test "x$fd_check" = "x1"
+then
+ AC_DEFINE([BSC_FD_CHECK],[1],[Instrument the bsc_register_fd])
+fi
+
AC_OUTPUT(
libosmocore.pc