aboutsummaryrefslogtreecommitdiffstats
path: root/hostapd/hostapd_cli.c
diff options
context:
space:
mode:
authorMohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>2015-06-25 12:42:48 (GMT)
committerJouni Malinen <j@w1.fi>2015-07-17 21:15:36 (GMT)
commitb8e5426dadd43534fbd7e73bd3c2a5c743d0eccf (patch)
tree1fa6566dbee6c226fa5f3f1bf3ea599a478897c3 /hostapd/hostapd_cli.c
parentb6387212f5ce94653b22492061240cd609759532 (diff)
downloadhostap-b8e5426dadd43534fbd7e73bd3c2a5c743d0eccf.zip
hostap-b8e5426dadd43534fbd7e73bd3c2a5c743d0eccf.tar.gz
hostap-b8e5426dadd43534fbd7e73bd3c2a5c743d0eccf.tar.bz2
hostapd_cli: Allow PID file to be specified
This can help when running multiple hostapd_cli instances per interface and need to kill them correspondingly. Signed-off-by: Mohammed Shafi Shajakhan <mohammed@qti.qualcomm.com>
Diffstat (limited to 'hostapd/hostapd_cli.c')
-rw-r--r--hostapd/hostapd_cli.c7
1 files changed, 5 insertions, 2 deletions
diff --git a/hostapd/hostapd_cli.c b/hostapd/hostapd_cli.c
index 42f8bd4..320d56a 100644
--- a/hostapd/hostapd_cli.c
+++ b/hostapd/hostapd_cli.c
@@ -112,7 +112,7 @@ static void usage(void)
"\n"
"usage: hostapd_cli [-p<path>] [-i<ifname>] [-hvB] "
"[-a<path>] \\\n"
- " [-G<ping interval>] [command..]\n"
+ " [-P<pid file>] [-G<ping interval>] [command..]\n"
"\n"
"Options:\n"
" -h help (show this usage text)\n"
@@ -1317,7 +1317,7 @@ int main(int argc, char *argv[])
return -1;
for (;;) {
- c = getopt(argc, argv, "a:BhG:i:p:v");
+ c = getopt(argc, argv, "a:BhG:i:p:P:v");
if (c < 0)
break;
switch (c) {
@@ -1343,6 +1343,9 @@ int main(int argc, char *argv[])
case 'p':
ctrl_iface_dir = optarg;
break;
+ case 'P':
+ pid_file = optarg;
+ break;
default:
usage();
return -1;