Author: zont Date: Tue Aug 21 14:58:51 2012 New Revision: 239501 URL: http://svn.freebsd.org/changeset/base/239501
Log: - Use pid_t type instead of just int. Approved by: kib (mentor) Modified: head/usr.bin/truss/extern.h head/usr.bin/truss/setup.c head/usr.bin/truss/syscalls.c head/usr.bin/truss/truss.h Modified: head/usr.bin/truss/extern.h ============================================================================== --- head/usr.bin/truss/extern.h Tue Aug 21 13:46:46 2012 (r239500) +++ head/usr.bin/truss/extern.h Tue Aug 21 14:58:51 2012 (r239501) @@ -32,7 +32,7 @@ */ extern int setup_and_wait(char **); -extern int start_tracing(int); +extern int start_tracing(pid_t); extern void restore_proc(int); extern void waitevent(struct trussinfo *); extern const char *ioctlname(unsigned long val); Modified: head/usr.bin/truss/setup.c ============================================================================== --- head/usr.bin/truss/setup.c Tue Aug 21 13:46:46 2012 (r239500) +++ head/usr.bin/truss/setup.c Tue Aug 21 14:58:51 2012 (r239501) @@ -57,7 +57,7 @@ __FBSDID("$FreeBSD$"); #include "truss.h" #include "extern.h" -static int child_pid; +static pid_t child_pid; /* * setup_and_wait() is called to start a process. All it really does @@ -69,7 +69,7 @@ static int child_pid; int setup_and_wait(char *command[]) { - int pid; + pid_t pid; int waitval; pid = vfork(); @@ -100,7 +100,7 @@ setup_and_wait(char *command[]) */ int -start_tracing(int pid) +start_tracing(pid_t pid) { int waitval; int ret; Modified: head/usr.bin/truss/syscalls.c ============================================================================== --- head/usr.bin/truss/syscalls.c Tue Aug 21 13:46:46 2012 (r239500) +++ head/usr.bin/truss/syscalls.c Tue Aug 21 14:58:51 2012 (r239501) @@ -464,7 +464,7 @@ get_syscall(const char *name) */ static int -get_struct(int pid, void *offset, void *buf, int len) +get_struct(pid_t pid, void *offset, void *buf, int len) { struct ptrace_io_desc iorequest; @@ -539,7 +539,7 @@ char * print_arg(struct syscall_args *sc, unsigned long *args, long retval, struct trussinfo *trussinfo) { char *tmp = NULL; - int pid = trussinfo->pid; + pid_t pid = trussinfo->pid; switch (sc->type & ARG_MASK) { case Hex: Modified: head/usr.bin/truss/truss.h ============================================================================== --- head/usr.bin/truss/truss.h Tue Aug 21 13:46:46 2012 (r239500) +++ head/usr.bin/truss/truss.h Tue Aug 21 14:58:51 2012 (r239501) @@ -45,7 +45,7 @@ struct threadinfo struct trussinfo { - int pid; + pid_t pid; int flags; int pr_why; int pr_data; _______________________________________________ svn-src-head@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-head To unsubscribe, send any mail to "svn-src-head-unsubscr...@freebsd.org"