about summary refs log tree commit diff
diff options
context:
space:
mode:
authorSven Wischnowsky <wischnow@users.sourceforge.net>2000-04-25 11:17:24 +0000
committerSven Wischnowsky <wischnow@users.sourceforge.net>2000-04-25 11:17:24 +0000
commitf5dcbf9f19e52f8704bb23548498c575870cef06 (patch)
tree848bdf9ba9832e4ca68eb0cea7bb4782b9bb6d94
parent2f90974c38247cfcbcea034aaa861a3ed700bdc5 (diff)
downloadzsh-f5dcbf9f19e52f8704bb23548498c575870cef06.tar.gz
zsh-f5dcbf9f19e52f8704bb23548498c575870cef06.tar.xz
zsh-f5dcbf9f19e52f8704bb23548498c575870cef06.zip
don't always ignore backslashes in paths when testing file type (10912)
-rw-r--r--ChangeLog3
-rw-r--r--Src/Zle/compresult.c3
2 files changed, 6 insertions, 0 deletions
diff --git a/ChangeLog b/ChangeLog
index 84be75d70..c80d834ab 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2000-04-25  Sven Wischnowsky  <wischnow@informatik.hu-berlin.de>
 
+	* 10912: Src/Zle/compresult.c: don't always ignore backslashes in
+ 	paths when testing file type
+	
 	* 10910: Completion/Base/_tilde, Completion/Core/_all_labels,
  	Completion/Core/_requested: small fix for _requested to be able to
  	use _all_labels from within it
diff --git a/Src/Zle/compresult.c b/Src/Zle/compresult.c
index 3875987c5..8c09a9491 100644
--- a/Src/Zle/compresult.c
+++ b/Src/Zle/compresult.c
@@ -705,6 +705,9 @@ ztat(char *nam, struct stat *buf, int ls)
 {
     char b[PATH_MAX], *p;
 
+    if (!(ls ? lstat(nam, buf) : stat(nam, buf)))
+	return 0;
+
     for (p = b; p < b + sizeof(b) - 1 && *nam; nam++)
 	if (*nam == '\\' && nam[1])
 	    *p++ = *++nam;