[PATCH 2/2] wext: Change wpa_printf to wpa_msg.
Wed Feb 16 08:35:25 PST 2011
On 02/16/2011 08:20 AM, Jouni Malinen wrote:
> On Fri, Dec 03, 2010 at 12:56:05PM -0800, Ben Greear wrote:
>> This helps us identify which interface a message pertains too.
>> Lots of void casting in this code, so this could use a good
> This is a bit problematic (same for driver_nl80211.c) since the ctx
> pointer given to src/drivers/driver_*.c in init() (or hapd in hapd_init)
> is not explicitly documented to be usable as the context pointer for
> wpa_msg(). At the moment, it looks like this would work with the current
> use cases in hostap.git, but there is no guarantee on that remaining to
> be the case.
> I'm not sure what would be the best approach here.. One option would be
> to add a separate context pointer that is then use with wpa_msg (or
> wpa_dbg) calls. Another option would be to document the limitation that
> the same ctx pointer can be used for both purposes.
What would be really nice is to use a base-class and not pass void*
all over the place! This can be done easily enough, even in C.
Ben Greear <greearb at candelatech.com>
Candela Technologies Inc http://www.candelatech.com
More information about the Hostap