diff options
author | dzwdz | 2023-06-17 17:53:23 +0200 |
---|---|---|
committer | dzwdz | 2023-06-17 17:53:23 +0200 |
commit | 657585026a375d2cb2d06ab400f9deb487d89a17 (patch) | |
tree | f777a03d136405128d1ea5b947101d863f3e81de /src/user/app/ps | |
parent | 84fa0102c6906252999967925f32098ab6d5a259 (diff) |
libc: expand psdata into a proper struct, include executable base
this is very useful for debugging userland programs using the qemu gdb stub
Diffstat (limited to 'src/user/app/ps')
-rw-r--r-- | src/user/app/ps/ps.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/user/app/ps/ps.c b/src/user/app/ps/ps.c index d2b9ded..76a5841 100644 --- a/src/user/app/ps/ps.c +++ b/src/user/app/ps/ps.c @@ -33,7 +33,7 @@ main(void) warn("couldn't open \"%s\"", procbuf); strcpy(procbuf, "(can't peek)"); } else { - fseek(g, (long)_libc_psdata, SEEK_SET); + fseek(g, (long)&_psdata_loc->desc, SEEK_SET); if (fread(procbuf, 1, 128, g) <= 0) { strcpy(procbuf, "(no psdata)"); } |