aboutsummaryrefslogtreecommitdiffstats
path: root/wpa_supplicant
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 /wpa_supplicant
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 'wpa_supplicant')
-rw-r--r--wpa_supplicant/wpa_cli.c18
1 files changed, 0 insertions, 18 deletions
diff --git a/wpa_supplicant/wpa_cli.c b/wpa_supplicant/wpa_cli.c
index 7614218..42be5b6 100644
--- a/wpa_supplicant/wpa_cli.c
+++ b/wpa_supplicant/wpa_cli.c
@@ -90,24 +90,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 int wpa_cli_show_event(const char *event)
{
const char *start;