From 11db21cc1c00d63c6b23ec6b3a3bdb48728b2b64 Mon Sep 17 00:00:00 2001 From: Jelmer Vernooij Date: Thu, 27 Mar 2003 12:08:46 +0000 Subject: Use the new modules system in VFS. If a module can't be loaded with the new modules system, we still fall back to the old system. (This used to be commit cebe8d8b424f10006f2f791a8f086c6c8a7f5d57) --- source3/modules/vfs_audit.c | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) (limited to 'source3/modules/vfs_audit.c') diff --git a/source3/modules/vfs_audit.c b/source3/modules/vfs_audit.c index 1944c98e53..fa9bf67a67 100644 --- a/source3/modules/vfs_audit.c +++ b/source3/modules/vfs_audit.c @@ -98,10 +98,9 @@ static vfs_op_tuple audit_ops[] = { /* VFS initialisation function. Return vfs_op_tuple array back to SAMBA. */ -vfs_op_tuple *vfs_init(int *vfs_version, struct vfs_ops *def_vfs_ops, +static vfs_op_tuple *audit_init(const struct vfs_ops *def_vfs_ops, struct smb_vfs_handle_struct *vfs_handle) { - *vfs_version = SMB_VFS_INTERFACE_VERSION; memcpy(&default_vfs_ops, def_vfs_ops, sizeof(struct vfs_ops)); audit_handle = vfs_handle; @@ -111,12 +110,6 @@ vfs_op_tuple *vfs_init(int *vfs_version, struct vfs_ops *def_vfs_ops, return audit_ops; } -/* VFS finalization function. */ -void vfs_done(connection_struct *conn) -{ - syslog(SYSLOG_PRIORITY, "VFS_DONE: vfs module unloaded\n"); -} - /* Implementation of vfs_ops. Pass everything on to the default operation but log event first. */ @@ -276,3 +269,8 @@ static int audit_fchmod_acl(struct files_struct *fsp, int fd, mode_t mode) return result; } + +int vfs_audit_init(void) +{ + return smb_register_vfs("audit", audit_init, SMB_VFS_INTERFACE_VERSION); +} -- cgit