fix: fix SYS_GETUSER missing in syscall switch, use getuser in shell username print

This commit is contained in:
2026-03-24 17:34:07 +01:00
parent 1542e80a3f
commit f3ea22935f
2 changed files with 15 additions and 8 deletions
+9 -8
View File
@@ -17,14 +17,15 @@ char session_home[64] = "";
// ---- Session info (read once at startup) ----
void read_session() {
auto doc = montauk::config::load("session");
const char* name = doc.get_string("session.username", "");
if (name[0]) {
scopy(session_user, name, sizeof(session_user));
scopy(session_home, "0:/users/", sizeof(session_home));
scat(session_home, session_user, sizeof(session_home));
}
doc.destroy();
// TODO Why is getuser treated as not defined in VSCode intellisense?
montauk::getuser(
(char *)&session_user, // Buffer
32 // Buffer max size
);
scopy(session_home, "0:/users/", sizeof(session_home));
scat(session_home, session_user, sizeof(session_home));
}
// ---- Command history ----