kernel/ptrace.c BUG_ON fixes
PATCH 1/1 kernel/ptrace.c BUG_ON fixes
Hello
ptrace.c has some references to BUG() in form
if (condition)
BUG();
I've changed them in BUG_ON(condition);
Cheers,
Eduard Roccatello
usr/src/linux/kernel/ptrace.c renamed from usr/src/linux/kernel/ptrace.c.orig +4 -4
@@ -28,8 +28,8 @@*/ void __ptrace_link (task_t *child,task_t *new_parent) { -if (!list_empty (&child->ptrace_list)) -BUG (); +BUG_ON (!list_empty (&child->ptrace_list)); +if (child->parent == new_parent)return ;list_add (&child->ptrace_list, &child->parent->ptrace_children);
@@ -46,8 +46,8 @@ void __ptrace_link(task_t *child, task_t*/ void __ptrace_unlink (task_t *child) { -if (!child->ptrace) -BUG (); +BUG_ON (!child->ptrace); + child->ptrace =0 ;if (list_empty (&child->ptrace_list))return ;
Quoted 1 line · Eduard Roccatello
I've changed them in
BUG_ON(condition);
i forgot... this patch is against to 2.6.2-rc1
best regards,
Eduard