changeset: 4465:732b87cfabf21f6d1bad716db6ea58624f8f556e
tag: tip
user: Aidan Kehoe <kehoea(a)parhasard.net>
date: Wed May 21 16:55:14 2008 +0200
files: src/ChangeLog src/fileio.c tests/ChangeLog tests/automated/mule-tests.el
description:
Document Win32 symlink behaviour; adjust tests to take it into a/c.
src/ChangeLog addition:
2008-05-21 Aidan Kehoe <kehoea(a)parhasard.net>
* fileio.c (Fmake_symbolic_link):
Document behaviour when the underlying OS doesn't support symbolic
links.
tests/ChangeLog addition:
2008-05-21 Aidan Kehoe <kehoea(a)parhasard.net>
* automated/mule-tests.el (featurep):
Make sure that working symlinks are available before testing
their functionality.
Also, don't bomb out on deleting the other temporary files if
deleting the first threw an error.
diff -r 61aff09a758969c7690c17763a5f4fb9e6594662 -r
732b87cfabf21f6d1bad716db6ea58624f8f556e src/ChangeLog
--- a/src/ChangeLog Thu May 15 07:46:41 2008 -0400
+++ b/src/ChangeLog Wed May 21 16:55:14 2008 +0200
@@ -1,3 +1,9 @@ 2008-05-13 Aidan Kehoe <kehoea@parhasa
+2008-05-21 Aidan Kehoe <kehoea(a)parhasard.net>
+
+ * fileio.c (Fmake_symbolic_link):
+ Document behaviour when the underlying OS doesn't support symbolic
+ links.
+
2008-05-13 Aidan Kehoe <kehoea(a)parhasard.net>
* emacs.c (SHEBANG_EXE_PROGNAME_LENGTH):
diff -r 61aff09a758969c7690c17763a5f4fb9e6594662 -r
732b87cfabf21f6d1bad716db6ea58624f8f556e src/fileio.c
--- a/src/fileio.c Thu May 15 07:46:41 2008 -0400
+++ b/src/fileio.c Wed May 21 16:55:14 2008 +0200
@@ -2199,6 +2199,10 @@ unless optional third argument OK-IF-ALR
unless optional third argument OK-IF-ALREADY-EXISTS is non-nil.
A number as third arg means request confirmation if LINKNAME already exists.
This happens for interactive use with M-x.
+
+On platforms where symbolic links are not available, any file handlers will
+be run, but the check for the existence of LINKNAME will not be done, and
+the symbolic link will not be created.
*/
(filename, linkname, ok_if_already_exists))
{
diff -r 61aff09a758969c7690c17763a5f4fb9e6594662 -r
732b87cfabf21f6d1bad716db6ea58624f8f556e tests/ChangeLog
--- a/tests/ChangeLog Thu May 15 07:46:41 2008 -0400
+++ b/tests/ChangeLog Wed May 21 16:55:14 2008 +0200
@@ -1,3 +1,11 @@ 2008-02-14 Aidan Kehoe <kehoea@parhasa
+2008-05-21 Aidan Kehoe <kehoea(a)parhasard.net>
+
+ * automated/mule-tests.el (featurep):
+ Make sure that working symlinks are available before testing
+ their functionality.
+ Also, don't bomb out on deleting the other temporary files if
+ deleting the first threw an error.
+
2008-02-14 Aidan Kehoe <kehoea(a)parhasard.net>
* automated/case-tests.el (let):
diff -r 61aff09a758969c7690c17763a5f4fb9e6594662 -r
732b87cfabf21f6d1bad716db6ea58624f8f556e tests/automated/mule-tests.el
--- a/tests/automated/mule-tests.el Thu May 15 07:46:41 2008 -0400
+++ b/tests/automated/mule-tests.el Wed May 21 16:55:14 2008 +0200
@@ -372,19 +372,32 @@ This is a naive implementation in Lisp.
;; used scaron as the Latin-2 character, and make-temp-name errored
;; on OS X. LATIN CAPITAL LETTER D WITH STROKE does not decompose.
(name1 (make-temp-name prefix))
- (name2 (make-temp-name prefix)))
- ;; This is how you suppress output from `message', called by `write-region'
+ (name2 (make-temp-name prefix))
+ (name3 (make-temp-name prefix))
+ working-symlinks)
(Assert (not (equal name1 name2)))
(Assert (not (file-exists-p name1)))
+ ;; This is how you suppress output from `message', called by `write-region'
(Silence-Message
(write-region (point-min) (point-max) name1))
(Assert (file-exists-p name1))
- (when (fboundp 'make-symbolic-link)
+ (Silence-Message
+ (write-region (point-min) (point-max) name3))
+ (Assert (file-exists-p name3))
+ (condition-case nil
+ (make-symbolic-link name1 name3)
+ (file-already-exists
+ ;; If we actually have functioning symlinks, we end up here, since
+ ;; name3 already exists and OK-IF-ALREADY-EXISTS was not specified.
+ (setq working-symlinks t)))
+ (when working-symlinks
(make-symbolic-link name1 name2)
(Assert (file-exists-p name2))
(Assert (equal (file-truename name2) name1))
(Assert (equal (file-truename name1) name1)))
- (ignore-file-errors (delete-file name1) (delete-file name2)))
+ (ignore-file-errors (delete-file name1))
+ (ignore-file-errors (delete-file name2))
+ (ignore-file-errors (delete-file name3)))
;; Add many more file operation tests here...
_______________________________________________
XEmacs-Patches mailing list
XEmacs-Patches(a)xemacs.org
http://calypso.tux.org/cgi-bin/mailman/listinfo/xemacs-patches