Abort on "call nesting too deep" error
It's better to abort() here, imho. Helped me while debugging too
Signed-off-by: Arnaud Patard <apatard@mandriva.com>
diff --git a/handle_event.c b/handle_event.c
index dba20b6..22c79f4 100644
--- a/handle_event.c
+++ b/handle_event.c
@@ -639,7 +639,8 @@
debug(DEBUG_FUNCTION, "callstack_push_syscall(pid=%d, sysnum=%d)", proc->pid, sysnum);
/* FIXME: not good -- should use dynamic allocation. 19990703 mortene. */
if (proc->callstack_depth == MAX_CALLDEPTH - 1) {
- fprintf(stderr, "Error: call nesting too deep!\n");
+ fprintf(stderr, "%s: Error: call nesting too deep!\n", __func__);
+ abort();
return;
}
@@ -662,7 +663,8 @@
debug(DEBUG_FUNCTION, "callstack_push_symfunc(pid=%d, symbol=%s)", proc->pid, sym->name);
/* FIXME: not good -- should use dynamic allocation. 19990703 mortene. */
if (proc->callstack_depth == MAX_CALLDEPTH - 1) {
- fprintf(stderr, "Error: call nesting too deep!\n");
+ fprintf(stderr, "%s: Error: call nesting too deep!\n", __func__);
+ abort();
return;
}