wpa_cli: Allow tab as alternative separator for cli_txt_list words
To be able to reuse the add/del word utility functions for lines containing
tabs allow both space and tab as word separators.
Signed-off-by: Mikael Kanstrup <mikael.kanstrup@sonymobile.com>
diff --git a/wpa_supplicant/wpa_cli.c b/wpa_supplicant/wpa_cli.c
index 27f10f1..4cdb138 100644
--- a/wpa_supplicant/wpa_cli.c
+++ b/wpa_supplicant/wpa_cli.c
@@ -174,6 +174,8 @@
char *buf;
end = os_strchr(txt, ' ');
if (end == NULL)
+ end = os_strchr(txt, '\t');
+ if (end == NULL)
end = txt + os_strlen(txt);
buf = dup_binstr(txt, end - txt);
if (buf == NULL)
@@ -222,6 +224,8 @@
int ret;
end = os_strchr(txt, ' ');
if (end == NULL)
+ end = os_strchr(txt, '\t');
+ if (end == NULL)
end = txt + os_strlen(txt);
buf = dup_binstr(txt, end - txt);
if (buf == NULL)