]> git.sur5r.net Git - i3/i3status/commitdiff
Don't leak skfd on errors. Don't spam stderr if the iface isn't present.
authorFernando Tarlá Cardoso Lemos <fernandotcl@gmail.com>
Tue, 29 Jun 2010 23:08:21 +0000 (20:08 -0300)
committerMichael Stapelberg <michael@stapelberg.de>
Wed, 30 Jun 2010 08:49:40 +0000 (10:49 +0200)
src/print_wireless_info.c

index 50cf8e4b08047c57ec82774978f3c6458a4cb228..22a9c3191f8dfa69fd6f1768070e6a641b18e65d 100644 (file)
@@ -39,7 +39,7 @@ static int get_wireless_info(const char *interface, wireless_info_t *info) {
 
         wireless_config wcfg;
         if (iw_get_basic_config(skfd, interface, &wcfg) < 0) {
-            perror("iw_get_basic_config");
+            close(skfd);
             return 0;
         }