Messages in this thread Patch in this message | | | Date | Thu, 24 Nov 2011 10:17:16 +0300 | From | Dan Carpenter <> | Subject | [patch] uprobes: add_utask() returns an ERR_PTR() not NULL |
| |
We need to check for IS_ERR() here (add_utask() never returns NULL).
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/kernel/uprobes.c b/kernel/uprobes.c index 2493191..3360057 100644 --- a/kernel/uprobes.c +++ b/kernel/uprobes.c @@ -1387,8 +1387,10 @@ void uprobe_notify_resume(struct pt_regs *regs) if (!utask) { utask = add_utask(); /* Cannot Allocate; re-execute the instruction. */ - if (!utask) + if (IS_ERR(utask)) { + utask = NULL; goto cleanup_ret; + } } utask->active_uprobe = u; handler_chain(u, regs);
| |