From 62bee04fc03af0dee77683745e5c27cfa5255ceb Mon Sep 17 00:00:00 2001 From: Bananymous Date: Tue, 3 Dec 2024 16:21:18 +0200 Subject: [PATCH] LibC: Implement dummy utime that just checks file existance --- userspace/libraries/LibC/utime.cpp | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/userspace/libraries/LibC/utime.cpp b/userspace/libraries/LibC/utime.cpp index 9112603b..727dd942 100644 --- a/userspace/libraries/LibC/utime.cpp +++ b/userspace/libraries/LibC/utime.cpp @@ -1,8 +1,11 @@ -#include - #include +#include +#include -int utime(const char*, const struct utimbuf*) +int utime(const char* filename, const struct utimbuf* times) { - ASSERT_NOT_REACHED(); + fprintf(stddbg, "TODO: utime(\"%s\", %p)\n", filename, times); + + struct stat st; + return stat(filename, &st); }