diff options
author | reyk <reyk@openbsd.org> | 2006-09-28 17:43:42 +0000 |
---|---|---|
committer | reyk <reyk@openbsd.org> | 2006-09-28 17:43:42 +0000 |
commit | 2a7c90004ab80e1fccb143e179ea5c7a4c6acf35 (patch) | |
tree | 683e4ccdf8f87fb95b1c98a0729a7f91bc1d54d1 /usr.sbin/hostapd/hostapd.c | |
parent | fix the configuration parser for event rules: correct handling of (diff) | |
download | wireguard-openbsd-2a7c90004ab80e1fccb143e179ea5c7a4c6acf35.tar.xz wireguard-openbsd-2a7c90004ab80e1fccb143e179ea5c7a4c6acf35.zip |
hostapd tree search speedup via inlined compare function
suggested by Mike Belopuhov (mkb at crypt dot org dot ru)
Diffstat (limited to 'usr.sbin/hostapd/hostapd.c')
-rw-r--r-- | usr.sbin/hostapd/hostapd.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/usr.sbin/hostapd/hostapd.c b/usr.sbin/hostapd/hostapd.c index b00ef0e9e9e..75142247bab 100644 --- a/usr.sbin/hostapd/hostapd.c +++ b/usr.sbin/hostapd/hostapd.c @@ -1,4 +1,4 @@ -/* $OpenBSD: hostapd.c,v 1.29 2006/06/01 22:09:09 reyk Exp $ */ +/* $OpenBSD: hostapd.c,v 1.30 2006/09/28 17:43:42 reyk Exp $ */ /* * Copyright (c) 2004, 2005 Reyk Floeter <reyk@openbsd.org> @@ -52,6 +52,8 @@ void hostapd_usage(void); void hostapd_udp_init(struct hostapd_config *); void hostapd_sig_handler(int); +static __inline int + hostapd_entry_cmp(struct hostapd_entry *, struct hostapd_entry *); struct hostapd_config hostapd_cfg; @@ -612,7 +614,7 @@ hostapd_entry_update(struct hostapd_table *table, struct hostapd_entry *entry) } } -int +static __inline int hostapd_entry_cmp(struct hostapd_entry *a, struct hostapd_entry *b) { return (memcmp(a->e_lladdr, b->e_lladdr, IEEE80211_ADDR_LEN)); |