accounting stop with no accounting data

Jouni Malinen jkmaline
Sun Aug 22 22:24:23 PDT 2004

On Fri, Aug 06, 2004 at 08:41:51AM +0200, Gunter Burchardt wrote:

> There are some cases an accounting stop packet is sent without a term
> cause and bytes/packet statistic. I think the problem is that
> sta_remove is called at some locations and after it ap_free_sta is
> called. sta_remove removes the station from driver and so it removes
> the statistic.
> First location: wpa_sta_disconnect()
> Here no term-cause is set. Then sta_remove is called. After is you call
> ap_handle_timer via eloop with STA_REMOVE. This causes a call to
> ap_free_sta. I think the call to sta_remove() in wpa_sta_disconnect is
> unnecessary because in ap_free_sta() it is called also!

This was fixed with the patch you sent later.

> Second location: iapp_process_add_notify()
> Why only remove the station from kernel driver. ap_free_sta() is the
> better choise!?

Hmm.. This code is probably older than accounting and it has not been
updated lately. I changed it to use similar construct that WPA is using

Jouni Malinen                                            PGP id EFC895FA

More information about the Hostap mailing list