diff --git a/kernel/cred.c b/kernel/cred.c index ff7bc071991c3dd008f5d67078bfde1cefb46bf4..fc222e4acfb0b30ddd2c8f0bca98a3788f8aecf0 100644 --- a/kernel/cred.c +++ b/kernel/cred.c @@ -529,6 +529,7 @@ struct cred *prepare_kernel_cred(struct task_struct *daemon) error: put_cred(new); + put_cred(old); return NULL; } EXPORT_SYMBOL(prepare_kernel_cred);