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

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

[nongnu] elpa/inf-ruby 6a2d3c9c28 3/6: properly clean up temp file over


From: ELPA Syncer
Subject: [nongnu] elpa/inf-ruby 6a2d3c9c28 3/6: properly clean up temp file over tramp
Date: Thu, 28 Sep 2023 13:01:33 -0400 (EDT)

branch: elpa/inf-ruby
commit 6a2d3c9c28c8809ebd98833b198996c20271d846
Author: bo-tato <122528427+bo-tato@users.noreply.github.com>
Commit: bo-tato <122528427+bo-tato@users.noreply.github.com>

    properly clean up temp file over tramp
---
 inf-ruby.el | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)

diff --git a/inf-ruby.el b/inf-ruby.el
index d72fe20144..5a93232916 100755
--- a/inf-ruby.el
+++ b/inf-ruby.el
@@ -705,13 +705,14 @@ This function also removes itself from 
`pre-command-hook'."
               (if (file-remote-p default-directory)
                   (concat (file-remote-p default-directory) "/tmp")
                 temporary-file-directory))
-             (tempfile (make-temp-file "rb")))
+             (tempfile (make-temp-file "rb"))
+             (tempfile-local-name (inf-ruby-file-local-name tempfile)))
         (with-temp-file tempfile
-          (insert (format "File.delete(%S)\n" tempfile))
+          (insert (format "File.delete(%S)\n" tempfile-local-name))
           (insert string))
         (comint-send-string (inf-ruby-proc)
                             (format "eval(File.read(%S), %s%s)\n"
-                                    (inf-ruby-file-local-name tempfile)
+                                    tempfile-local-name
                                     inf-ruby-eval-binding
                                     file-and-lineno
                                     tempfile))))))



reply via email to

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