[PATCH] tdb: runtime check for robust mutexes may hang
Ralph Böhme
slow at samba.org
Mon Mar 13 09:57:50 UTC 2017
On Mon, Mar 13, 2017 at 06:49:00AM +1300, Andrew Bartlett wrote:
> On Sun, 2017-03-12 at 14:14 +0100, Ralph Böhme via samba-technical
> wrote:
> >
> > As there's no POSIX function to change the signal mask of all threads
> > in a
> > process, this problem can't be solved by a change to
> > tdb_runtime_check_for_robust_mutexes().
> >
> > Attached patch *moves* the runtime check to a library initializer
> > which
> > guarantees that only one thread exists in the process when the
> > function is run.
>
> Why can we assert this is true?
>
> Surely if tdb is loaded into a program by being linked to a plugin, eg
> dlopen(), the library initializer will run then, with threads already
> running?
golly, you're right. I missed this case.
Back to the drawing board I guess, unless we decide we don't care about this use
case. We probably should care, might actually be used by the Gnome VFS, who
knows.
Cheerio!
-slow
More information about the samba-technical
mailing list