[Aggregator] Use owl_timestamp_equals()

This commit is contained in:
Matteo Cypriani 2011-03-25 10:39:02 +01:00
parent 67a271596c
commit 15f4436628
2 changed files with 9 additions and 4 deletions

5
TODO
View File

@ -22,6 +22,11 @@
- Use locks to read/write the AP list
Currently, several threads can access the list simultaneously, and
that's not cool!
- got_request(): option for the maximal difference time
For implicit packet, we consider that packet from the same MAC and
received within an interval of 10ms are part of the same
request. We should define an option to allow user to choose the
time he wants.
- Allow blank parameters for output options.
- Fix segfault on SIGINT.

View File

@ -703,9 +703,9 @@ void got_request(owl_captured_request request)
while (tmp_request != NULL)
{ // Research criterion: MAC and transmission time
if (owl_mac_equals(request.mobile_mac_addr_bytes,
tmp_request->mobile_mac_addr_bytes) == 1
&& owl_time_elapsed_ms(request.request_time,
tmp_request->request_time) == 0)
tmp_request->mobile_mac_addr_bytes)
&& owl_timestamp_equals(request.request_time,
tmp_request->request_time))
break ; // If the request exists, we stop on it
tmp_request = tmp_request->next ;
}
@ -718,7 +718,7 @@ void got_request(owl_captured_request request)
// times on the APs less than 10 ms
// TODO : define an option for the maximal difference time.
if (owl_mac_equals(request.mobile_mac_addr_bytes,
tmp_request->mobile_mac_addr_bytes) == 1
tmp_request->mobile_mac_addr_bytes)
&& owl_time_elapsed_ms(request.start_time,
tmp_request->request_time) <= 10)
break ; // If the request exists, we stop on it