Fixes: bug#34074
Reported by 林宝龙 <lbl52001@gmail.com>.
* lisp/progmodes/flymake-proc.el
(flymake-proc--delete-temp-directory): Use directory-file-name.
(defun flymake-proc--delete-temp-directory (dir-name)
"Attempt to delete temp dir created by `flymake-proc-create-temp-with-folder-structure', do not fail on error."
(let* ((temp-dir temporary-file-directory)
- (suffix (substring dir-name (1+ (length temp-dir)))))
+ (suffix (substring dir-name (1+ (length (directory-file-name temp-dir))))))
(while (> (length suffix) 0)
(setq suffix (directory-file-name suffix))