mirror of
https://github.com/pocketpy/pocketpy
synced 2026-08-07 06:37:10 +08:00
Update os.c
This commit is contained in:
parent
5546291c91
commit
7435251873
@ -48,6 +48,7 @@ static bool os_chdir(int argc, py_Ref argv) {
|
||||
}
|
||||
|
||||
static bool os_getcwd(int argc, py_Ref argv) {
|
||||
PY_CHECK_ARGC(0);
|
||||
char buf[1024];
|
||||
if(!platform_getcwd(buf, sizeof(buf))) return OSError("getcwd() failed");
|
||||
py_newstr(py_retval(), buf);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user