[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

Re: [Libevent-users] Found a warning in libevent 2.0.21



On Mon, Sep 16, 2013 at 12:08 PM, Ralph Castain <rhc@xxxxxxxxxxxx> wrote:
> Hi Nick
>
> Sorry for delayed response - been a little hectic, and had to think about this a bit. I gather your concern is that (a) someone builds libevent on a 10.7 or above Mac, and then (b) someone executes that binary on a pre-10.7 Mac, and therefore arc4random_buf is not found? If so, I would think you'd generate a loader failure before you could check for a NULL pointer - yes?

It turns out that this isn't actually the case; people reported
getting errors at call time, not at link time.

> Problem is that I get this warning on OSX as well as on Linux, so confining it to OSX wouldn't remove it. Only thing I can think of (assuming the loader failure doesn't occur) is to have a runtime check of what OSX level we are on, and then protect the call to arc4random_buf using that instead of checking for a NULL pointer.

Hm. That's an option. We could also suppress the warning for that one
line, maybe, or find a way to do the check that doesn't trigger the
warning?

yrs,
-- 
Nick
***********************************************************************
To unsubscribe, send an e-mail to majordomo@xxxxxxxxxxxxx with
unsubscribe libevent-users    in the body.