[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[elpa] master 03a5464 57/76: Changed channel to an integer.

From: Ian Dunn
Subject: [elpa] master 03a5464 57/76: Changed channel to an integer.
Date: Thu, 23 Feb 2017 19:42:53 -0500 (EST)

branch: master
commit 03a546421e6525ac853bdeb3f3188f7893d0bc68
Author: Ian Dunn <address@hidden>
Commit: Ian Dunn <address@hidden>

    Changed channel to an integer.
    * enwc-nm.el (enwc-nm-get-wireless-nw-props): Changed channel to an integer.
    * enwc-wicd.el (enwc-wicd-build-prop-list): Changed channel to an integer.
 lisp/enwc-nm.el   | 4 ++--
 lisp/enwc-wicd.el | 7 +++++--
 2 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/lisp/enwc-nm.el b/lisp/enwc-nm.el
index 363cb3d..b0b51f8 100644
--- a/lisp/enwc-nm.el
+++ b/lisp/enwc-nm.el
@@ -336,8 +336,8 @@ PROP from that access point.  It also sets the channel from 
       (bssid    . ,(cdr (assoc "HwAddress" props)))
       (strength . ,(cdr (assoc "Strength" props)))
       (encrypt  . ,(or (enwc-nm-get-encryption-type nw) "Unsecured"))
-      (channel  . ,(number-to-string (enwc-nm--freq-to-channel
-                                      (cdr (assoc "Frequency" props))))))))
+      (channel  . ,(enwc-nm--freq-to-channel
+                    (cdr (assoc "Frequency" props)))))))
 (defun enwc-nm-get-encryption-type (nw)
   "The NetworkManager get encryption type function.
diff --git a/lisp/enwc-wicd.el b/lisp/enwc-wicd.el
index cb64fa8..b321c00 100644
--- a/lisp/enwc-wicd.el
+++ b/lisp/enwc-wicd.el
@@ -142,7 +142,7 @@ Just returns a number sequence."
   "The handler for `enwc-wicd-get-wireless-network-property'.
 This receives the value of network property PROP,
 and appends the value to `enwc-wicd-prop-values'."
-  (push `(,prop . ,(car args)) enwc-wicd-prop-values)
+  (push (cons prop (car args)) enwc-wicd-prop-values)
   (setq enwc-wicd-prop-num (1+ enwc-wicd-prop-num)))
 (defun enwc-wicd-prop-to-prop (prop)
@@ -175,7 +175,10 @@ from wireless network with id ID."
      (let* ((cur-prop (assoc det prop-list))
             (act-det (enwc-wicd-prop-to-prop det))
             (act-prop (when cur-prop (cdr cur-prop))))
-       `(,act-det . ,act-prop)))
+       (when (or (string-equal det "essid")
+                 (string-equal det "channel"))
+         (setq act-prop (string-to-number cur-prop)))
+       (cons act-det act-prop)))
 (defun enwc-wicd-get-wireless-nw-props (id)

reply via email to

[Prev in Thread] Current Thread [Next in Thread]