LKML Archive on lore.kernel.org
help / color / mirror / Atom feed
* [patch 1/1] epoll move kfree inside ep_free ...
@ 2007-05-13 19:42 Davide Libenzi
0 siblings, 0 replies; only message in thread
From: Davide Libenzi @ 2007-05-13 19:42 UTC (permalink / raw)
To: Linux Kernel Mailing List; +Cc: Andrew Morton
Move the kfree() call inside the ep_free() function.
Signed-off-by: Davide Libenzi <davidel@xmailserver.org>
- Davide
Index: linux-2.6.21-git17.epmod/fs/eventpoll.c
===================================================================
--- linux-2.6.21-git17.epmod.orig/fs/eventpoll.c 2007-05-13 12:39:09.000000000 -0700
+++ linux-2.6.21-git17.epmod/fs/eventpoll.c 2007-05-13 12:40:04.000000000 -0700
@@ -469,18 +469,16 @@
}
mutex_unlock(&epmutex);
-
mutex_destroy(&ep->mtx);
+ kfree(ep);
}
static int ep_eventpoll_release(struct inode *inode, struct file *file)
{
struct eventpoll *ep = file->private_data;
- if (ep) {
+ if (ep)
ep_free(ep);
- kfree(ep);
- }
DNPRINTK(3, (KERN_INFO "[%p] eventpoll: close() ep=%p\n", current, ep));
return 0;
@@ -1107,7 +1105,6 @@
error_free:
ep_free(ep);
- kfree(ep);
error_return:
DNPRINTK(3, (KERN_INFO "[%p] eventpoll: sys_epoll_create(%d) = %d\n",
current, size, error));
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2007-05-13 19:42 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2007-05-13 19:42 [patch 1/1] epoll move kfree inside ep_free Davide Libenzi
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).