emacs-elpa-diffs
[Top][All Lists]
Advanced

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

[elpa] externals/async 386cdbb441: New user var to prevent prompting for


From: ELPA Syncer
Subject: [elpa] externals/async 386cdbb441: New user var to prevent prompting for password (Issue #181)
Date: Tue, 28 Nov 2023 15:57:18 -0500 (EST)

branch: externals/async
commit 386cdbb441211483a1d5277717a68f4a2074860e
Author: Thierry Volpiatto <thievol@posteo.net>
Commit: Thierry Volpiatto <thievol@posteo.net>

    New user var to prevent prompting for password (Issue #181)
    
    This may be needed to prevent tramp-password-prompt-regexp matching
    arbitrary data in filter process.
---
 async.el | 9 ++++++++-
 1 file changed, 8 insertions(+), 1 deletion(-)

diff --git a/async.el b/async.el
index 99da5d375c..810f610b9c 100644
--- a/async.el
+++ b/async.el
@@ -44,6 +44,12 @@
   "Default function to remove text properties in variables."
   :type 'function)
 
+(defcustom async-prompt-for-password t
+  "Prompt for password in parent Emacs if needed when non nil.
+When this is nil child Emacs will hang forever when a user interaction
+for password is required unless a password is stored in a \".authinfo\" file."
+  :type 'boolean)
+
 (defvar async-debug nil)
 (defvar async-send-over-pipe t)
 (defvar async-in-child-emacs nil)
@@ -221,7 +227,8 @@ lasts complete line.  Every time we get new input, we try 
to look
 for newline, and if found, process the entire line and bump the
 marker position to the end of this next line."
   (with-current-buffer (process-buffer proc)
-    (when (and (boundp 'tramp-password-prompt-regexp)
+    (when (and async-prompt-for-password
+               (boundp 'tramp-password-prompt-regexp)
                (string-match tramp-password-prompt-regexp string))
       (process-send-string
        proc (concat (read-passwd (match-string 0 string)) "\n")))



reply via email to

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