summaryrefslogtreecommitdiff
path: root/source4/ntvfs
diff options
context:
space:
mode:
Diffstat (limited to 'source4/ntvfs')
-rw-r--r--source4/ntvfs/posix/pvfs_search.c3
-rw-r--r--source4/ntvfs/posix/pvfs_wait.c3
-rw-r--r--source4/ntvfs/posix/vfs_posix.c3
-rw-r--r--source4/ntvfs/sysdep/inotify.c6
4 files changed, 5 insertions, 10 deletions
diff --git a/source4/ntvfs/posix/pvfs_search.c b/source4/ntvfs/posix/pvfs_search.c
index 32bef1ae53..4d218fbe9c 100644
--- a/source4/ntvfs/posix/pvfs_search.c
+++ b/source4/ntvfs/posix/pvfs_search.c
@@ -35,9 +35,8 @@
/*
destroy an open search
*/
-static int pvfs_search_destructor(void *ptr)
+static int pvfs_search_destructor(struct pvfs_search_state *search)
{
- struct pvfs_search_state *search = ptr;
DLIST_REMOVE(search->pvfs->search.list, search);
idr_remove(search->pvfs->search.idtree, search->handle);
return 0;
diff --git a/source4/ntvfs/posix/pvfs_wait.c b/source4/ntvfs/posix/pvfs_wait.c
index 5750c0fe08..90c9b60efe 100644
--- a/source4/ntvfs/posix/pvfs_wait.c
+++ b/source4/ntvfs/posix/pvfs_wait.c
@@ -102,9 +102,8 @@ static void pvfs_wait_timeout(struct event_context *ev,
/*
destroy a pending wait
*/
-static int pvfs_wait_destructor(void *ptr)
+static int pvfs_wait_destructor(struct pvfs_wait *pwait)
{
- struct pvfs_wait *pwait = ptr;
if (pwait->msg_type != -1) {
messaging_deregister(pwait->msg_ctx, pwait->msg_type, pwait);
}
diff --git a/source4/ntvfs/posix/vfs_posix.c b/source4/ntvfs/posix/vfs_posix.c
index 1682a94ac9..e7ef9bafd8 100644
--- a/source4/ntvfs/posix/vfs_posix.c
+++ b/source4/ntvfs/posix/vfs_posix.c
@@ -104,9 +104,8 @@ static void pvfs_setup_options(struct pvfs_state *pvfs)
}
}
-static int pvfs_state_destructor(void *ptr)
+static int pvfs_state_destructor(struct pvfs_state *pvfs)
{
- struct pvfs_state *pvfs = talloc_get_type(ptr, struct pvfs_state);
struct pvfs_file *f, *fn;
struct pvfs_search_state *s, *sn;
diff --git a/source4/ntvfs/sysdep/inotify.c b/source4/ntvfs/sysdep/inotify.c
index 33c4ff4928..5348006543 100644
--- a/source4/ntvfs/sysdep/inotify.c
+++ b/source4/ntvfs/sysdep/inotify.c
@@ -82,9 +82,8 @@ struct watch_context {
/*
destroy the inotify private context
*/
-static int inotify_destructor(void *ptr)
+static int inotify_destructor(struct inotify_private *in)
{
- struct inotify_private *in = talloc_get_type(ptr, struct inotify_private);
close(in->fd);
return 0;
}
@@ -308,9 +307,8 @@ static uint32_t inotify_map(struct notify_entry *e)
/*
destroy a watch
*/
-static int watch_destructor(void *ptr)
+static int watch_destructor(struct watch_context *w)
{
- struct watch_context *w = talloc_get_type(ptr, struct watch_context);
struct inotify_private *in = w->in;
int wd = w->wd;
DLIST_REMOVE(w->in->watches, w);