[PATCH 1/2] Change wpa_printf to wpa_msg in scan.c

Jouni Malinen j
Thu Feb 10 10:52:14 PST 2011

On Thu, Feb 10, 2011 at 10:39:00AM -0800, Ben Greear wrote:
> One thing about passing null to wpa_msg:  Doesn't that
> allow us to get messages over the cli interface tool, where
> wpa_printf does not?

No, the context pointer is needed for that to work.

> It seemed to me that converting all wpa_printfs to wpa_msg
> (or wpa_dbg) was going to be more flexible going forward.

For places where the suitable context pointer is available, yes.

> We could do a check for NULL and instead of printing
> "NULL:" is my patches did, it could just leave out the "NULL:",
> or maybe make more informed decisions about passing to
> the cli, log files, etc.

I actually already changed that to never use "NULL: " prefix.

Jouni Malinen                                            PGP id EFC895FA

More information about the Hostap mailing list