From 0eab6a8489e5690d0e526e177d39d6a6930784c7 Mon Sep 17 00:00:00 2001 From: Gavin Hayes Date: Fri, 26 Apr 2024 21:48:31 -0400 Subject: [PATCH] Revert "move back to proc, __static_yoink in paginate.c does not work" This reverts commit 38d0728107a528d7e12f6dc10f33917dd4083559. --- libc/{proc => x}/paginate.c | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) rename libc/{proc => x}/paginate.c (93%) diff --git a/libc/proc/paginate.c b/libc/x/paginate.c similarity index 93% rename from libc/proc/paginate.c rename to libc/x/paginate.c index dc37ad339..5b86705d0 100644 --- a/libc/proc/paginate.c +++ b/libc/x/paginate.c @@ -19,9 +19,7 @@ #include "libc/calls/calls.h" #include "libc/calls/syscall_support-nt.internal.h" #include "libc/dce.h" -#include "libc/intrin/kprintf.h" #include "libc/intrin/safemacros.internal.h" -#include "libc/intrin/weaken.h" #include "libc/limits.h" #include "libc/mem/gc.h" #include "libc/runtime/runtime.h" @@ -30,8 +28,6 @@ #include "libc/temp.h" #include "libc/x/x.h" -__static_yoink("__utf16to8"); - static char *get_pagerpath(char *pathbuf, size_t pathbufsz) { char *pagerpath; if (strcmp(nulltoempty(getenv("TERM")), "dumb") && isatty(0) && isatty(1) && @@ -47,10 +43,9 @@ static char *get_pagerpath(char *pathbuf, size_t pathbufsz) { static bool run_pager(char *args[hasatleast 3]) { char16_t widepath[PATH_MAX]; int n, pid; - kprintf("utf16to8 %p\n", _weaken(__utf16to8)); if (IsWindows() && !strcasecmp(args[0], "/C/Windows/System32/more.com") && - (!_weaken(__utf16to8) || ((n = __mkntpath(args[1], widepath)) == -1) || - !(args[1] = gc(_weaken(__utf16to8)(widepath, n, 0))))) { + (((n = __mkntpath(args[1], widepath)) == -1) || + !(args[1] = gc(utf16to8(widepath, n, 0))))) { return false; } if ((pid = fork()) != -1) {