summaryrefslogtreecommitdiff
path: root/source3/smbd/utmp.c
diff options
context:
space:
mode:
Diffstat (limited to 'source3/smbd/utmp.c')
-rw-r--r--source3/smbd/utmp.c23
1 files changed, 18 insertions, 5 deletions
diff --git a/source3/smbd/utmp.c b/source3/smbd/utmp.c
index 2c5a1abc82..9833a11f2d 100644
--- a/source3/smbd/utmp.c
+++ b/source3/smbd/utmp.c
@@ -21,8 +21,6 @@
#include "includes.h"
-#ifdef WITH_UTMP
-
/****************************************************************************
Reflect connection status in utmp/wtmp files.
T.D.Lee@durham.ac.uk September 1999
@@ -110,6 +108,23 @@ Notes:
****************************************************************************/
+#ifndef WITH_UTMP
+/*
+ * Not WITH_UTMP? Simply supply dummy routines.
+ */
+
+void sys_utmp_claim(const char *username, const char *hostname,
+ struct in_addr *ipaddr,
+ const char *id_str, int id_num)
+{}
+
+void sys_utmp_yield(const char *username, const char *hostname,
+ struct in_addr *ipaddr,
+ const char *id_str, int id_num)
+{}
+
+#else /* WITH_UTMP */
+
#include <utmp.h>
#ifdef HAVE_UTMPX_H
@@ -571,6 +586,4 @@ void sys_utmp_claim(const char *username, const char *hostname,
sys_utmp_update(&u, hostname, True);
}
-#else /* WITH_UTMP */
- void dummy_utmp(void) {}
-#endif
+#endif /* WITH_UTMP */