aboutsummaryrefslogtreecommitdiffstats
path: root/hostapd/hostapd_cli.c
diff options
context:
space:
mode:
authorJouni Malinen <j@w1.fi>2016-08-06 09:39:56 (GMT)
committerJouni Malinen <j@w1.fi>2016-08-06 09:39:56 (GMT)
commitfcc84b48b2827abbb84394a0acee6ac0ea74071f (patch)
treef157195fe5e0c525142e8e6ee4b26e1f507c60bd /hostapd/hostapd_cli.c
parente55df99ee6281f43de620c6bd46faee2ca0252a2 (diff)
downloadhostap-fcc84b48b2827abbb84394a0acee6ac0ea74071f.zip
hostap-fcc84b48b2827abbb84394a0acee6ac0ea74071f.tar.gz
hostap-fcc84b48b2827abbb84394a0acee6ac0ea74071f.tar.bz2
cli: Share a common get_cmd_arg_num() implementation
wpa_cli and hostapd_cli had identical copies of this function. Signed-off-by: Jouni Malinen <j@w1.fi>
Diffstat (limited to 'hostapd/hostapd_cli.c')
-rw-r--r--hostapd/hostapd_cli.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/hostapd/hostapd_cli.c b/hostapd/hostapd_cli.c
index 376a025..56f5fe2 100644
--- a/hostapd/hostapd_cli.c
+++ b/hostapd/hostapd_cli.c
@@ -74,24 +74,6 @@ static void usage(void)
}
-static int get_cmd_arg_num(const char *str, int pos)
-{
- int arg = 0, i;
-
- for (i = 0; i <= pos; i++) {
- if (str[i] != ' ') {
- arg++;
- while (i <= pos && str[i] != ' ')
- i++;
- }
- }
-
- if (arg > 0)
- arg--;
- return arg;
-}
-
-
static void register_event_handler(struct wpa_ctrl *ctrl)
{
if (!ctrl_conn)