]> granicus.if.org Git - strace/blob - getcwd.c
file.c: move chdir parser to a separate file
[strace] / getcwd.c
1 #include "defs.h"
2
3 int
4 sys_getcwd(struct tcb *tcp)
5 {
6         if (exiting(tcp)) {
7                 if (syserror(tcp))
8                         tprintf("%#lx", tcp->u_arg[0]);
9                 else
10                         printpathn(tcp, tcp->u_arg[0], tcp->u_rval - 1);
11                 tprintf(", %lu", tcp->u_arg[1]);
12         }
13         return 0;
14 }