tech-userlevel archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Incompatible definition of "struct kevent" in "sys/event.h"



On Thu, Jun 04, 2009 at 09:01:44PM +0200, Jaromir Dolecek wrote:
> I think I used intptr_t so that the value could be used either as a poiner
> or just a flag (value) holder without casting.

Well, I'm not sure whether that was a good enough reason for the
API incompatibility. I agree that "intptr_t" might have been the
choice to start with. But as FreeBSD is using "void *" we should
have used that as well.

> What's the problem in libtorrent?

It assumes that "udata" is a typeless pointer. It e.g. assigns "NULL"
to it or compares it with another pointer.

        Kind regards

-- 
Matthias Scheler                                  http://zhadum.org.uk/


Home | Main Index | Thread Index | Old Index