lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sun, 15 May 2011 19:47:22 +0200
From:	Jan Kratochvil <jan.kratochvil@...hat.com>
To:	Tejun Heo <tj@...nel.org>
Cc:	Oleg Nesterov <oleg@...hat.com>, vda.linux@...glemail.com,
	linux-kernel@...r.kernel.org, torvalds@...ux-foundation.org,
	akpm@...ux-foundation.org, indan@....nu
Subject: Re: waitpid(WNOHANG) should report SIGCHLD-notified signals  [Re:
 [PATCH 09/11] job control: reorganize wait_task_stopped()]

Hi Tejun,

On Sun, 15 May 2011 18:47:05 +0200, Tejun Heo wrote:
> Hmmm... I could easily be wrong but AFAICS that shouldn't happen.  If
> you can reproduce the problem, please let us know.

I was unable to reproduce it before so OK, I will follow now your statement.


> > But if it is a case it should be fixed as there is no later notification when
> > to call waitpid(WNOHANG) again.  And sure the debugger cannot busy-loop poll
> > it.
> 
> But, the current WNOHANG wait is racy.  It's unlikely but definitely
> possible for WNOHANG to fail when it's expected to succeed (not the
> above case but more convoluted ones).

OK, so FYI it breaks current GDB.


> But, just out of curiosity, is there any reason the ptracer itself
> should be doing something other than waitpid() while tracee is
> running?  It's not like ptrace requests can be issued during that time
> and sleeping waitpid() is way saner mechanism to wait for tracee
> events than signal.

If the debugger wants to be single-threaded ("poll() model", not "threads
model") and it wants to communicate with user and examine debuggee symbols and
memory data it cannot use sleeping wait.  GDB is single-threaded and it
supports `set target-async 1': info '(gdb)Background Execution'


Thanks,
Jan
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ