History log of /src/usr.bin/ktrace/ktrace.c |
Revision | | Date | Author | Comments |
1.46 |
| 24-Jan-2013 |
christos | use O_CLOEXEC.
|
1.45 |
| 16-Sep-2011 |
joerg | branches: 1.45.2; 1.45.8; Use __dead
|
1.44 |
| 05-Feb-2011 |
yamt | update usage
|
1.43 |
| 11-Jan-2009 |
christos | branches: 1.43.4; merge christos-time_t
|
1.42 |
| 21-Jul-2008 |
lukem | branches: 1.42.6; Remove the \n and tabs from the __COPYRIGHT() strings. Tweak to use a consistent format.
|
1.41 |
| 08-Feb-2007 |
drochner | branches: 1.41.12; include <signal.h> where signal(3) is used
|
1.40 |
| 17-Jan-2007 |
hubertf | Remove duplicate #includes From Slava Semushin <slava.semushin@gmail.com>, via private mail
|
1.39 |
| 12-Dec-2005 |
wiz | Sync usage with man page.
|
1.38 |
| 11-Dec-2005 |
christos | Learn about ktrace v1 records.
|
1.37 |
| 16-Jul-2004 |
enami | - If fktrace(2) failed, just exit rather than waiting for trace output. - Reduce #ifdef a bit.
|
1.36 |
| 10-Jul-2004 |
enami | No need to pretty print the errno with err() or warn().
|
1.35 |
| 24-Jun-2004 |
christos | Fix a bug in ktruss and ktrace, where they would randomly stop tracing if the write to the ktraced file descriptor (when they used fktrace internally) would block. Fix by clearing the non-blocking bit in the file descriptor by default, so that the writes will block. This has the side effect of stopping the traced process. Add a flag to override (-n) this behavior and have the trace stop without blocking the traced process (the previous behavior). Fix lint, add checks to failed syscalls, ansify.
|
1.34 |
| 28-Feb-2004 |
enami | Replace rest of exit status `1' with EXIT_FAILURE.
|
1.33 |
| 28-Feb-2004 |
enami | Fix usage: - ktrace(1) takes -s. - ktruss(1) takes -l. - -C/-c and commands are exclusive. - make output fits 80 column.
|
1.32 |
| 28-Feb-2004 |
enami | - Make ktruss(1) works as expected when -c or -C is specified. - Include pid or file descriptor in error message when ktrace(2)/fktrace(2) failed. - Remove unnecessary cast.
|
1.31 |
| 28-Feb-2004 |
enami | Fix whitespace usage.
|
1.30 |
| 05-Jan-2004 |
jmmv | Homogenize usage messages: make the 'usage' word all lowercase, as this seems to be the most common practice in our tree.
|
1.29 |
| 24-Nov-2003 |
manu | Enable tracing of out of line data sent with Mach messages
|
1.28 |
| 07-Aug-2003 |
agc | Move UCB-licensed code from 4-clause to 3-clause licence.
Patches provided by Joel Baker in PR 22365, verified by myself.
|
1.27 |
| 17-Jul-2003 |
dsl | Grok KTR_EXEC_ENV and KTR_EXEC_ARG. Make ktrace -c default to removing all trace points (not just the default ones). Make kdump default to dumping everything in the trace file. Add 'A' (all) and '-' (remove following) to valid -t arguments. Dump data block of UNKNOWN trace points in hex + ascii. Make first time output with -R 0 (instead of time since epoch). Use svis() instead of vis() to get " escaped (as \") (needs fixed libc) Correctly pass unsigned values to svis() Update man pages.
|
1.26 |
| 09-Dec-2002 |
manu | Added support for dumping mach messages in ktrace/kdump. While we are there, KNFify a few functions.
|
1.25 |
| 19-Jul-2002 |
christos | PR/17643: Jared D. McNeill: ktrace leaves ktrace.out file with a kernel that does not support ktrace.
|
1.24 |
| 02-Sep-2001 |
assar | repair command-line parsing so that an error is generated if no pid or program is given (or input file for ktruss)
|
1.23 |
| 04-May-2001 |
simonb | Add a -s option to open the trace file with O_SYNC.
|
1.22 |
| 01-May-2001 |
simonb | Don't assume pipes are implemented as sockets -- don't call setsockopt() on the pipe descriptors.
|
1.21 |
| 19-Feb-2001 |
cgd | convert to use getprogname()
|
1.20 |
| 13-Nov-2000 |
jdolecek | constify
|
1.19 |
| 07-Jul-2000 |
itojun | errx?/warnx? audit. do not pass variable alone, use %s. idea from openbsd
|
1.18 |
| 03-Jul-2000 |
matt | Make gcc 2.96 (and maybe earlier) happier. Include <stdlib.h>,<string.>, etc. as appropriate to get exit,srncmp,abs,abort,etc. Add -I${.CURDIR} to a few Makefiles
|
1.17 |
| 27-May-2000 |
sommerfeld | branches: 1.17.4; Two tweaks: - For cleaner subprocess traces, malloc something before spawning, so the syscalls malloc does while initializing don't gunk up the trace. - Increase pipe buffer sizes.
|
1.16 |
| 13-Apr-2000 |
itohy | [ktruss] Use fork(2), not vfork(2). The child process of do_ktrace() does return and the stack is changed by another function call (execvp()). By using vfork() (my previous change), the execution of the parent process resumes on the modified stack. Oops. We could use vfork() carefully, but for now use fork().
Problem reported and investigated by Ethan Solomita <ethan@geocast.com>. Thanks.
|
1.15 |
| 10-Apr-2000 |
jdolecek | DTRT vs setemul() (for ktruss, similar to kdump.c)
|
1.14 |
| 10-Apr-2000 |
jdolecek | update to setemul() changes
|
1.13 |
| 29-Oct-1999 |
itohy | Make ktrace(1) not affect interactions between processes. Following examples show the cases.
% ktrace -f - false >/dev/null && echo wrong wrong % ktrace -f - -i /usr/sbin/update >/dev/null (does not return to command line)
That is, back out last change and restore the roles of parent/child for ktrace(1). The ktruss(1) stuff still remains. Yes, ktruss(1) has the problems. Better implementation is expected.
|
1.12 |
| 30-Jul-1999 |
darrenr | branches: 1.12.2; Change behaviour from running the command as the parent and ktrace/ktruss as the child to be ktruss/ktrace is the parent. This fixes a problem with ktruss where the prompt would be returned in the middle of output.
|
1.11 |
| 23-Jul-1999 |
itohy | Fix fowllowing problems:
1. If fork()ing, the program is executed twice. 2. If the ktruss(1) output is bufferd, the final output is not flushed (because it is executing).
% ktrace -f - rm >/dev/null usage: rm [-dfiPRrW] file ... usage: rm [-dfiPRrW] file ... % ktruss date | cat Fri Jul 23 12:09:45 JST 1999 Fri Jul 23 12:09:46 JST 1999 %
|
1.10 |
| 11-Jan-1999 |
kleink | In userland, pull in <errno.h> instead of <sys/errno.h> for the declaration of errno.
|
1.9 |
| 14-Jul-1998 |
nathanw | Make "ktrace -f" work again. Slightly klugy because of the #ifdef's for KTRUSS.
|
1.8 |
| 27-Jun-1998 |
christos | Appease gcc on arm32
|
1.7 |
| 27-Jun-1998 |
christos | fktrace support / ktruss additions.
|
1.6 |
| 27-Jun-1998 |
nathanw | Make "ktrace -c" work as documented. Update usage message to match reality.
Closes PR bin/5358.
|
1.5 |
| 23-Jul-1997 |
mikel | add explicit return types and prototypes for local functions use __COPYRIGHT and __RCSID macros, fix other gcc -Wall warnings
|
1.4 |
| 31-Aug-1995 |
jtc | Sync with 4.4lite2
|
1.3 |
| 03-Jan-1995 |
glass | reapplied patch that made ktrace behave well when kernel subsystem wasn't installed. some KNFing. fixes PR 663 as reported by muir@idiom.com
|
1.2 |
| 06-Oct-1994 |
mycroft | Add RCS ids.
|
1.1 |
| 11-May-1994 |
cgd | branches: 1.1.1; Initial revision
|
1.1.1.2 |
| 31-Aug-1995 |
jtc | imported from 44lite2
|
1.1.1.1 |
| 11-May-1994 |
cgd | updated ktrace
|
1.12.2.1 |
| 27-Dec-1999 |
wrstuden | Pull up to last week's -current.
|
1.17.4.1 |
| 28-Jul-2000 |
itojun | pullup (approved by releng-1-5) printf-like format pedant. do not pass string variable alone. use "%s". from openbsd.
/cvsroot/basesrc/usr.bin/biff/biff.c 1.6 -> 1.7 /cvsroot/basesrc/usr.bin/chpass/chpass.c 1.18 -> 1.19 /cvsroot/basesrc/usr.bin/finger/net.c 1.13 -> 1.14 /cvsroot/basesrc/usr.bin/finger/util.c 1.15 -> 1.16 /cvsroot/basesrc/usr.bin/hexdump/display.c 1.8 -> 1.9 /cvsroot/basesrc/usr.bin/ktrace/ktrace.c 1.18 -> 1.19 /cvsroot/basesrc/usr.bin/mail/lex.c 1.14 -> 1.15 /cvsroot/basesrc/usr.bin/modstat/modstat.c 1.14 -> 1.15 /cvsroot/basesrc/usr.bin/tcopy/tcopy.c 1.9 -> 1.10 /cvsroot/basesrc/usr.bin/tn3270/ascii/map3270.c 1.7 -> 1.8 /cvsroot/basesrc/usr.bin/tn3270/tools/mkmake/mkmake.y 1.7 -> 1.8 /cvsroot/basesrc/usr.bin/vmstat/dkstats.c 1.8 -> 1.9
|
1.41.12.1 |
| 18-Sep-2008 |
wrstuden | Sync with wrstuden-revivesa-base-2.
|
1.42.6.2 |
| 29-Dec-2008 |
christos | adjust for version 2.
|
1.42.6.1 |
| 21-Jul-2008 |
christos | file ktrace.c was added on branch christos-time_t on 2008-12-29 01:14:15 +0000
|
1.43.4.1 |
| 08-Feb-2011 |
bouyer | Sync with HEAD
|
1.45.8.1 |
| 25-Feb-2013 |
tls | resync with head
|
1.45.2.1 |
| 22-May-2014 |
yamt | sync with head.
for a reference, the tree before this commit was tagged as yamt-pagecache-tag8.
this commit was splitted into small chunks to avoid a limitation of cvs. ("Protocol error: too many arguments")
|