[PATCH v5 1/3] Introduce -l/--syscall-limit option

Dmitry V. Levin ldv at strace.io
Sun Mar 26 10:36:04 UTC 2023


On Sun, Mar 26, 2023 at 03:57:24PM +0530, Sahil Siddiq wrote:
> Hi,
> 
> Thank you for the feedback. There are a few things that I haven't
> really understood.
> 
> On Sunday, 26 March 2023 01:11:07 IST Dmitry V. Levin wrote:
> > On Mon, Mar 20, 2023 at 11:10:56AM +0530, Sahil Siddiq wrote:
> > [...]
> > for example, a tracee
> > doesn't invoke syscalls, strace -l won't finish.
> 
> I didn't understand this example. In case the argument to -l is greater
> than the number of syscalls that are invoked, wouldn't strace proceed
> as usual? If the tracee does not invoke any syscall, the syscall_limit
> counter will not decrease in syscall_exiting_trace().

Here is an example: take your strace--syscall-limit.c test, insert sleep(60)
right before the waitpid loop, and see what happens.


-- 
ldv


More information about the Strace-devel mailing list