[PATH 5/6] driver_nl80211.c: Return correct value

Bernhard Michael michael.bernhard
Sat Apr 12 06:10:19 PDT 2008


Signed-off-by: Michael Bernhard <michael.bernhard at bfh.ch>
---
hostapd/driver_nl80211.c |    4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/hostapd/driver_nl80211.c b/hostapd/driver_nl80211.c
index 152f615..cd2c66a 100644
--- a/hostapd/driver_nl80211.c
+++ b/hostapd/driver_nl80211.c
@@ -220,7 +220,7 @@ static int i802_set_encryption(const char *iface, void *priv, const char *alg,
    if (nl_send_auto_complete(drv->nl_handle, msg) < 0 ||
        (err = nl_wait_for_ack(drv->nl_handle)) < 0) {
        if (err != -ENOENT) {
-            err = 0;
+            ret = 0;
            goto out;
        }
    }
@@ -249,7 +249,7 @@ static int i802_set_encryption(const char *iface, void *priv, const char *alg,
    if (nl_send_auto_complete(drv->nl_handle, msg) < 0 ||
        (err = nl_wait_for_ack(drv->nl_handle)) < 0) {
        if (err != -ENOENT) {
-            err = 0;
+            ret = 0;
            goto out;
        }
    }




More information about the Hostap mailing list