Add new -T|--toggle option to strace
Conrad Scott
Conrad.Scott@dsl.pipex.com
Thu Jun 6 18:07:00 GMT 2002
As per a discussion yesterday with Chris, I've added a new option to
strace, -T or --toggle, to toggle tracing in a process already being
straced.
One other change I made was to replace a use of ExitProcess() with
exit() --- otherwise some error messages didn't appear since the stdio
buffers weren't being flushed.
I've also updated the section for strace in utils.sgml. I know that Joshua
has been holding off on changing utils.sgml (see
http://sources.redhat.com/ml/cygwin-patches/2002-q2/msg00276.html) so I
don't know whether you want this update or not. It's not much more than a
cut and paste from the usage message in strace.cc.
ChangeLog appended here and attached (to keep its format out of Outlook's
clutches).
// Conrad
2002-06-07 Conrad Scott <conrad.scott@dsl.pipex.com>
* strace.cc (toggle): New global variable.
(error): Use exit instead of ExitProcess so that stdio buffers get
flushed.
(create_child): Remove command line error checking.
(dostrace): Ditto.
(dotoggle): New function.
(usage): Add entry for new option -T|--toggle. Alphabetize.
(longopts): Add new option -T|--toggle.
(opts): Ditto.
(main): Handle new -T|--toggle option. Move all command line checking
here from other functions.
* utils.sgml: Update section for strace.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: strace.patch
Type: application/octet-stream
Size: 5129 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20020606/ec19f1a3/attachment.obj>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: utils.patch
Type: application/octet-stream
Size: 2072 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20020606/ec19f1a3/attachment-0001.obj>
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: ChangeLog.txt
URL: <http://cygwin.com/pipermail/cygwin-patches/attachments/20020606/ec19f1a3/attachment.txt>
More information about the Cygwin-patches
mailing list