From 3632f29912f6b637e0ac51e3c21bf875357b5031 Mon Sep 17 00:00:00 2001 From: oblique Date: Sat, 20 Sep 2014 23:12:48 +0300 Subject: [PATCH] rename can_have(_sta_and)_ap to can_be(_sta_and)_ap --- create_ap | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/create_ap b/create_ap index 8460908..2e565ce 100755 --- a/create_ap +++ b/create_ap @@ -141,7 +141,7 @@ get_adapter_info() { iw phy $PHY info } -can_have_sta_and_ap() { +can_be_sta_and_ap() { # iwconfig does not provide this information, assume false [[ $USE_IWCONFIG -eq 1 ]] && return 1 get_adapter_info "$1" | grep -E '{.* managed.* AP.*}' > /dev/null 2>&1 && return 0 @@ -149,7 +149,7 @@ can_have_sta_and_ap() { return 1 } -can_have_ap() { +can_be_ap() { # iwconfig does not provide this information, assume true [[ $USE_IWCONFIG -eq 1 ]] && return 0 get_adapter_info "$1" | grep -E '\* AP$' > /dev/null 2>&1 && return 0 @@ -548,14 +548,14 @@ if ! is_wifi_interface ${WIFI_IFACE}; then exit 1 fi -if ! can_have_ap ${WIFI_IFACE}; then +if ! can_be_ap ${WIFI_IFACE}; then echo "ERROR: Your adapter does not support AP (master) mode" >&2 exit 1 fi -if ! can_have_sta_and_ap ${WIFI_IFACE}; then +if ! can_be_sta_and_ap ${WIFI_IFACE}; then if is_wifi_connected ${WIFI_IFACE}; then - echo "ERROR: Your adapter can not be connected to an AP and at the same time transmit as an AP" >&2 + echo "ERROR: Your adapter can not be a station (i.e. be connected) and an AP at the same time" >&2 exit 1 elif [[ $NO_VIRT -eq 0 ]]; then echo "WARN: Your adapter does not fully support AP virtual interface, enabling --no-virt" >&2