diff options
author | Marcel Holtmann <marcel@holtmann.org> | 2008-12-13 00:44:24 +0100 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2008-12-13 00:44:24 +0100 |
commit | 2660c3971164ad79b5c758159cab3d3ab46bbdaf (patch) | |
tree | dec1693e982847c27398c2a8a553b9004a3f8635 | |
parent | 67a2843d9cdf1c961c98151fcb2224b2fbe3d03f (diff) | |
download | connman-2660c3971164ad79b5c758159cab3d3ab46bbdaf.tar.gz connman-2660c3971164ad79b5c758159cab3d3ab46bbdaf.tar.bz2 connman-2660c3971164ad79b5c758159cab3d3ab46bbdaf.zip |
Add callback to invalidate old results
-rw-r--r-- | plugins/supplicant.c | 3 | ||||
-rw-r--r-- | plugins/supplicant.h | 1 |
2 files changed, 4 insertions, 0 deletions
diff --git a/plugins/supplicant.c b/plugins/supplicant.c index 0a23039e..da274a03 100644 --- a/plugins/supplicant.c +++ b/plugins/supplicant.c @@ -789,6 +789,9 @@ static void scan_results_reply(DBusPendingCall *call, void *user_data) goto done; } + if (task->callback && task->callback->clear_results) + task->callback->clear_results(task->element); + for (i = 0; i < num_results; i++) get_network_properties(task, results[i]); diff --git a/plugins/supplicant.h b/plugins/supplicant.h index fa10a69d..48cf89b1 100644 --- a/plugins/supplicant.h +++ b/plugins/supplicant.h @@ -53,6 +53,7 @@ struct supplicant_network { struct supplicant_callback { void (*state_change) (struct connman_element *element, enum supplicant_state state); + void (*clear_results) (struct connman_element *element); void (*scan_result) (struct connman_element *element, struct supplicant_network *network); }; |