[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[elpa] externals/bluetooth 0108cbd 32/57: uses `read-from-minibuffer' in
From: |
Stefan Monnier |
Subject: |
[elpa] externals/bluetooth 0108cbd 32/57: uses `read-from-minibuffer' instead of `read-passwd' |
Date: |
Thu, 7 Nov 2019 23:28:54 -0500 (EST) |
branch: externals/bluetooth
commit 0108cbde29366f88b333152ce31da0e23c1156aa
Author: Raffael Stocker <address@hidden>
Commit: Raffael Stocker <address@hidden>
uses `read-from-minibuffer' instead of `read-passwd'
The pin is not encrypted on the bus, so it makes no sense to hide it in the
user interface.
---
bluetooth.el | 20 +++++++++-----------
1 file changed, 9 insertions(+), 11 deletions(-)
diff --git a/bluetooth.el b/bluetooth.el
index 3123389..2b77d25 100644
--- a/bluetooth.el
+++ b/bluetooth.el
@@ -440,19 +440,17 @@ This function only uses the first adapter reported by
Bluez."
(bluetooth--maybe-cancel-reject
(bluetooth--with-alias device
(save-match-data
- (let* ((pin (read-passwd (format "Enter Bluetooth PIN for `%s': "
alias)))
+ (let* ((pin (read-from-minibuffer
+ (format "Enter Bluetooth PIN for `%s': " alias)))
(trimmed-pin (substring pin 0 (min (length pin) 16)))
(case-fold-search nil))
- (unwind-protect
- (cond ((= 0 (length trimmed-pin))
- (message "PIN has zero length")
- nil)
- ((string-match "[^[:alnum:]]" trimmed-pin)
- (message "PIN contains non-alphanumeric characters")
- nil)
- (t trimmed-pin))
- (clear-string pin)
- (clear-string trimmed-pin)))))))
+ (cond ((= 0 (length trimmed-pin))
+ (message "PIN has zero length")
+ nil)
+ ((string-match "[^[:alnum:]]" trimmed-pin)
+ (message "PIN contains non-alphanumeric characters")
+ nil)
+ (t trimmed-pin)))))))
(defun bluetooth--display-pin-code (device pincode)
"Display the PINCODE for DEVICE."
- [elpa] externals/bluetooth 3365413 33/57: corrects the major mode check in `list-bluetooth-devices', (continued)
- [elpa] externals/bluetooth 3365413 33/57: corrects the major mode check in `list-bluetooth-devices', Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth b47bddc 36/57: switches device-info buffer to special mode, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 42a9487 35/57: moves `hl-line-mode' to end of init so hl is shown at startup, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 325febd 16/57: adds Imenu integration to Readme feature list, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth f0e5047 18/57: removes unnecessary quotes before lambdas and corrects indentation, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 738347b 19/57: adds TAGS to .gitignore, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 28e9eb2 21/57: wraps @body in progn in bluetooth--maybe-cancel-reject, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 4133a10 13/57: makes mode idempotent, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 3c25a8c 23/57: adds basic service class UUID parsing, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 5219f05 31/57: fixes a compile error and adds customization, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 0108cbd 32/57: uses `read-from-minibuffer' instead of `read-passwd',
Stefan Monnier <=
- [elpa] externals/bluetooth 1ec2997 22/57: uses the correct bus (:system) for the callback methods, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 83344c8 20/57: cleans up display code, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth fe926e9 28/57: puts functions before the long uuid defconsts for readability, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth c473128 40/57: adds repository URL to mode (entry) command docstring, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth eb1d4ea 25/57: adds UUID and service/device class parsing and display, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth f9bfd26 39/57: fixes a grammatical mistake in Readme.org, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 565cfec 38/57: adds more elaborate usage information, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 7714f6b 45/57: updates Readme, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 1f3b244 47/57: makes checkdoc and package-lint happy, Stefan Monnier, 2019/11/07
- [elpa] externals/bluetooth 9d79f61 46/57: puts the key bindings in their own defvar (as is usual), Stefan Monnier, 2019/11/07