* bug#50149: [PATCH] Don't echo empty string
@ 2021-08-21 15:28 Colin Woodbury
2021-08-22 14:27 ` Lars Ingebrigtsen
0 siblings, 1 reply; 2+ messages in thread
From: Colin Woodbury @ 2021-08-21 15:28 UTC (permalink / raw)
To: 50149
[-- Attachment #1.1: Type: text/plain, Size: 51 bytes --]
This fixes an oversight from my last patch. Thanks!
[-- Attachment #1.2: Type: text/html, Size: 198 bytes --]
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-Don-t-echo-empty-string.patch --]
[-- Type: text/x-patch; name="0001-Don-t-echo-empty-string.patch", Size: 903 bytes --]
From 8fd60db517739df38d47dd656219b910c2251418 Mon Sep 17 00:00:00 2001
From: Colin Woodbury <colin@fosskers.ca>
Date: Sat, 21 Aug 2021 08:23:18 -0700
Subject: [PATCH] Don't echo empty string
* lisp/files.el (file-name-with-extension): Avoid echoing a filename
string known to be empty.
---
lisp/files.el | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/lisp/files.el b/lisp/files.el
index f0baa4fac6..ba362827ee 100644
--- a/lisp/files.el
+++ b/lisp/files.el
@@ -5033,7 +5033,7 @@ FILENAME has the format of a directory.
See also `file-name-sans-extension'."
(let ((extn (string-trim-left extension "[.]")))
(cond ((string-empty-p filename)
- (error "Empty filename: %s" filename))
+ (error "Empty filename"))
((string-empty-p extn)
(error "Malformed extension: %s" extension))
((directory-name-p filename)
--
2.33.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2021-08-22 14:27 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-08-21 15:28 bug#50149: [PATCH] Don't echo empty string Colin Woodbury
2021-08-22 14:27 ` Lars Ingebrigtsen
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.