ports/144760: sysutils/tmux: shell not working in tmux any more

Gary Jennejohn gary.jennejohn at freenet.de
Wed Mar 17 12:06:40 UTC 2010


On Wed, 17 Mar 2010 12:05:08 +0200
Andriy Gapon <avg at icyb.net.ua> wrote:

> on 17/03/2010 04:46 wen heping said the following:
> > Hi,
> > 
> >    Would you test this patch ?
> >   If it works, I shall commit it.
> > 
> 
> I think that it would be interesting/useful to understand in what respect FreeBSD
> kqueue is considered 'broken' by tmux code.
> 

Actually it's the kqueue handling in devel/libevent, which is used by tmux,
which considers our kequeue(2) implementation to be broken.

The code in kqueue.c:kq_init() from libevent calls kevent() [kqueue(2)]
with nchanges=1 and nevents=64.  It assumes that kevent() will always
return 1 on success.  According to kqueue(2) kevent will return up to
nevents on success.  I'm not sure whether our kevent() should return 1
because nchanges=1 or not.

So the question is whether kq_init() is making a bad assumption or not.

In any case it seems that devel/libevent should be fixed, if necessary,
rather than applying a bandaid to tmux.

---
Gary Jennejohn


More information about the freebsd-ports mailing list