diff options
| author | Eli Zaretskii | 2001-07-03 13:02:55 +0000 |
|---|---|---|
| committer | Eli Zaretskii | 2001-07-03 13:02:55 +0000 |
| commit | f4a97216175cf74710b62ea8da0922705d4f14c1 (patch) | |
| tree | d8acdfa774cd4eaeb01d3bf363b37a69d7f82a75 | |
| parent | 51a91c091083098a2f347564594ca169175bba0f (diff) | |
| download | emacs-f4a97216175cf74710b62ea8da0922705d4f14c1.tar.gz emacs-f4a97216175cf74710b62ea8da0922705d4f14c1.zip | |
(ff-find-the-other-file): Use file-name-nondirectory
instead of string-match to find the basename of the file. From
Pascal Obry <p.obry@wanadoo.fr>.
| -rw-r--r-- | lisp/find-file.el | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/lisp/find-file.el b/lisp/find-file.el index d59f10d22bd..5e5f3766084 100644 --- a/lisp/find-file.el +++ b/lisp/find-file.el | |||
| @@ -422,8 +422,7 @@ If optional IN-OTHER-WINDOW is non-nil, find the file in another window." | |||
| 422 | (buffer-file-name) | 422 | (buffer-file-name) |
| 423 | "/none.none")) | 423 | "/none.none")) |
| 424 | 424 | ||
| 425 | (string-match ".*/\\(.+\\)$" pathname) | 425 | (setq fname (file-name-nondirectory pathname) |
| 426 | (setq fname (substring pathname (match-beginning 1) (match-end 1)) | ||
| 427 | no-match nil | 426 | no-match nil |
| 428 | match (car alist)) | 427 | match (car alist)) |
| 429 | 428 | ||