aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKim F. Storm2007-03-17 23:44:57 +0000
committerKim F. Storm2007-03-17 23:44:57 +0000
commitc4c52bb78af68b4c40685f912113f0bd730f0848 (patch)
tree7be3c42826a56dc3e0421be465c114b26725bcf7 /src
parente3a1ed3b5b15cbf947f01d06e973b45bf10ddb50 (diff)
downloademacs-c4c52bb78af68b4c40685f912113f0bd730f0848.tar.gz
emacs-c4c52bb78af68b4c40685f912113f0bd730f0848.zip
2007-03-17 Richard M. Stallman <rms@gnu.org>
(file_name_completion): Gcpro NAME.
Diffstat (limited to 'src')
-rw-r--r--src/dired.c11
1 files changed, 9 insertions, 2 deletions
diff --git a/src/dired.c b/src/dired.c
index c542f8019db..ee76fe47be2 100644
--- a/src/dired.c
+++ b/src/dired.c
@@ -670,8 +670,15 @@ file_name_completion (file, dirname, all_flag, ver_flag, predicate)
670 if (!NILP (predicate)) 670 if (!NILP (predicate))
671 { 671 {
672 Lisp_Object decoded; 672 Lisp_Object decoded;
673 Lisp_Object val;
674 struct gcpro gcpro1;
675
676 GCPRO1 (name);
673 decoded = Fexpand_file_name (DECODE_FILE (name), dirname); 677 decoded = Fexpand_file_name (DECODE_FILE (name), dirname);
674 if (NILP (call1 (predicate, decoded))) 678 val = call1 (predicate, decoded);
679 UNGCPRO;
680
681 if (NILP (val))
675 continue; 682 continue;
676 } 683 }
677 684
@@ -694,7 +701,7 @@ file_name_completion (file, dirname, all_flag, ver_flag, predicate)
694 compare = min (bestmatchsize, len); 701 compare = min (bestmatchsize, len);
695 p1 = SDATA (bestmatch); 702 p1 = SDATA (bestmatch);
696 p2 = (unsigned char *) dp->d_name; 703 p2 = (unsigned char *) dp->d_name;
697 matchsize = scmp(p1, p2, compare); 704 matchsize = scmp (p1, p2, compare);
698 if (matchsize < 0) 705 if (matchsize < 0)
699 matchsize = compare; 706 matchsize = compare;
700 if (completion_ignore_case) 707 if (completion_ignore_case)