Dired patch for Emacs 19.29

Sandy Rutherford (sandy@itp.phys.ethz.ch)
Sun, 23 Jul 1995 15:48:51 +0200


There is a problem with dired-7 and Emacs 19 in that sometimes file
lines are not getting updated.  This is because now `buffer-substring'
returns text properties, and comparing two strings with `equal' test
these text properties.  The patch below changes `equal' to
`string-equal', which fixes the problem.

--sandy

==============================================================================
diff -c /home/sandy/efs/1.14/dired.el /sandy@spiff.gnu.ai.mit.edu:/home/fsf/sandy/lisp-19/efs/dired.el
*** /home/sandy/efs/1.14/dired.el	Sun Jul 23 15:41:02 1995
--- /sandy@spiff.gnu.ai.mit.edu:/home/fsf/sandy/lisp-19/efs/dired.el	Sun Jul 23 15:41:02 1995
***************
*** 2301,2307 ****
  				 (error "Need absolute pathname for %s"
  					file)))
  	  (let ((base (file-name-nondirectory file))
! 		(boundary (dired-subdir-max)))
  	    (while (and (not found)
  			;; filenames are preceded by SPC, this makes
  			;; the search faster (e.g. for the filename "-"!).
--- 2301,2308 ----
  				 (error "Need absolute pathname for %s"
  					file)))
  	  (let ((base (file-name-nondirectory file))
! 		(boundary (dired-subdir-max))
! 		fn)
  	    (while (and (not found)
  			;; filenames are preceded by SPC, this makes
  			;; the search faster (e.g. for the filename "-"!).
***************
*** 2309,2315 ****
  	      ;; Match could have BASE just as initial substring or
  	      ;; or in permission bits or date or
  	      ;; not be a proper filename at all:
! 	      (if (equal base (dired-get-filename 'no-dir t))
  		  ;; Must move to filename since an (actually
  		  ;; correct) match could have been elsewhere on the
  		  ;; line (e.g. "-" would match somewhere in the
--- 2310,2317 ----
  	      ;; Match could have BASE just as initial substring or
  	      ;; or in permission bits or date or
  	      ;; not be a proper filename at all:
! 	      (if (and (setq fn (dired-get-filename 'no-dir t))
! 		       (string-equal fn base))
  		  ;; Must move to filename since an (actually
  		  ;; correct) match could have been elsewhere on the
  		  ;; line (e.g. "-" would match somewhere in the