Skip to content
Snippets Groups Projects
Commit b16e9b44 authored by pw's avatar pw
Browse files

Fix guard against "/" in pathname name or type to consider that

the argument may be other than a string.
parent a5b6497a
No related branches found
No related tags found
No related merge requests found
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
;;; Carnegie Mellon University, and has been placed in the public domain. ;;; Carnegie Mellon University, and has been placed in the public domain.
;;; ;;;
(ext:file-comment (ext:file-comment
"$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/pathname.lisp,v 1.48 2001/03/27 20:23:45 pw Exp $") "$Header: /Volumes/share2/src/cmucl/cvs2git/cvsroot/src/code/pathname.lisp,v 1.49 2001/04/05 13:40:02 pw Exp $")
;;; ;;;
;;; ********************************************************************** ;;; **********************************************************************
;;; ;;;
...@@ -676,11 +676,12 @@ a host-structure or string." ...@@ -676,11 +676,12 @@ a host-structure or string."
;; A bit of sanity checking on user arguments. ;; A bit of sanity checking on user arguments.
(flet ((check-component-validity (name name-or-type) (flet ((check-component-validity (name name-or-type)
(let ((unix-directory-separator #\/)) (when (stringp name)
(when (eq host (pathname-host *default-pathname-defaults*)) (let ((unix-directory-separator #\/))
(when (find unix-directory-separator name) (when (eq host (pathname-host *default-pathname-defaults*))
(warn "Silly argument for a unix ~A: ~S" (when (find unix-directory-separator name)
name-or-type name)))))) (warn "Silly argument for a unix ~A: ~S"
name-or-type name)))))))
(check-component-validity name :pathname-name) (check-component-validity name :pathname-name)
(check-component-validity type :pathname-type)) (check-component-validity type :pathname-type))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment