On 2018-09-20 09:13:42, Alexandre Ratchov wrote:
> On Wed, Sep 19, 2018 at 11:32:40PM +0200, michal.lyszc...@bofc.pl wrote:
> > Hello,
> >
> > I've stumbled upon a weird problem. Long story short, I try to open
> > fifo two times, once O_WRONLY and once O_RDONLY, both in separate
> > threads - but on process. Unfortunately both threads are locked in
> > open() functions.
> >
> > I prepared very small program that reproduces this problem for me,
> > please see attached file and note that there is no error handling
> > for readability.
> >
> > !!! Also note, this program may get stuck in D state,
> > and you won't be able to SIGKILL it.
> >
> > Anyone got any idea why is this happening? Is something wrong with
> > my code?
>
> This is a kernel bug, no program may behave like this.
>
> > It works properly on netbsd, freebsd, aix, hpux and linux.
> >
> > I don't know what info exactly you might need, but here is uname,
> > it's almost clean system, I didn't make much changes, and
> > especially not in the core.
> >
> > # uname -a
> > OpenBSD bbs-i686-builder-openbsd.kurwinet.pl 6.2 GENERIC#163 i386
>
> This is a old OpenBSD version; I reproduced it on 6.3 but not
> on -current (this doesn't mean the bug was fixed).

I confirm, just upgraded my system to: OpenBSD 6.3 GENERIC#490 i386 and
problem is the same.

I found a workaround. When I change flags in both open() to O_RDWR, the
problem goes away, it's not much but it's something.

Should I post a bug report? I cannot find a way to check if that was
already reported or not.

-- 
Best Regards

Reply via email to