From 2af7c802b6c11da439ad8af82cc3dc7a58528664 Mon Sep 17 00:00:00 2001 From: Justine Tunney Date: Tue, 31 Oct 2023 21:58:39 -0700 Subject: [PATCH] Stub out getutline and pututline --- libc/runtime/utmp.c | 33 +++++++++------------------------ 1 file changed, 9 insertions(+), 24 deletions(-) diff --git a/libc/runtime/utmp.c b/libc/runtime/utmp.c index a7ead4854..a11b8113c 100644 --- a/libc/runtime/utmp.c +++ b/libc/runtime/utmp.c @@ -20,22 +20,9 @@ #include "libc/errno.h" #include "libc/runtime/utmpx.h" -void setutent(void) { -} - -void endutent(void) { -} - void endutxent(void) { } -struct utmp *getutent(void) { - return 0; -} - -void updwtmp(const char *x, const struct utmp *y) { -} - void updwtmpx(const char *x, const struct utmpx *y) { } @@ -46,10 +33,6 @@ struct utmpx *pututxline(const struct utmpx *p) { void setutxent(void) { } -struct utmp *getutid(const struct utmp *x) { - return 0; -} - struct utmpx *getutxent(void) { return 0; } @@ -67,10 +50,12 @@ int __utmpxname() { return -1; } -int utmpname(const char *x) { - return __utmpxname(); -} - -int utmpxname(const char *x) { - return __utmpxname(); -} +__weak_reference(endutxent, endutent); +__weak_reference(setutxent, setutent); +__weak_reference(getutxent, getutent); +__weak_reference(getutxid, getutid); +__weak_reference(getutxline, getutline); +__weak_reference(pututxline, pututline); +__weak_reference(updwtmpx, updwtmp); +__weak_reference(__utmpxname, utmpname); +__weak_reference(__utmpxname, utmpxname);