emacs-devel
[Top][All Lists]
Advanced

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

[patch] Use in `file-truename' in `flymake-create-temp-inplace'


From: Arne Jørgensen
Subject: [patch] Use in `file-truename' in `flymake-create-temp-inplace'
Date: Fri, 20 Jul 2012 11:39:40 +0200
User-agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.1 (darwin)

If the temp-name in `flymake-create-temp-inplace' is going through
symlinks reported errors might not get catched if they contain the
expanded file name.

Wrapping temp-name in `file-truename' will make the file names
consistent in the error reports and in flymake.

Kind regards,
Arne

--- flymake.el-OLD      2012-07-20 11:36:07.000000000 +0200
+++ flymake.el  2012-07-20 11:36:16.000000000 +0200
@@ -1529,10 +1529,10 @@
     (error "Invalid file-name"))
   (or prefix
       (setq prefix "flymake"))
-  (let* ((temp-name   (concat (file-name-sans-extension file-name)
-                             "_" prefix
-                             (and (file-name-extension file-name)
-                                  (concat "." (file-name-extension 
file-name))))))
+  (let* ((temp-name (file-truename (concat (file-name-sans-extension file-name)
+                                           "_" prefix
+                                           (and (file-name-extension file-name)
+                                                (concat "." 
(file-name-extension file-name)))))))
     (flymake-log 3 "create-temp-inplace: file=%s temp=%s" file-name temp-name)
     temp-name))
 

reply via email to

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