Mercurial > emacs
comparison src/dired.c @ 90596:6823a91487f2
Merge from emacs--devo--0
Patches applied:
* emacs--devo--0 (patch 399-413)
- Update from CVS
- Rcirc update from Ryan Yeske
- Merge from gnus--rel--5.10
- Miscellaneous tq-related fixes.
* gnus--rel--5.10 (patch 126-127)
- Merge from emacs--devo--0
- Update from CVS
Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-105
author | Miles Bader <miles@gnu.org> |
---|---|
date | Mon, 28 Aug 2006 04:33:45 +0000 |
parents | 8a8e69664178 85113179d2d1 |
children | bc10a33dd40b |
comparison
equal
deleted
inserted
replaced
90595:fd59c4164a14 | 90596:6823a91487f2 |
---|---|
133 Lisp_Object | 133 Lisp_Object |
134 directory_files_internal_unwind (dh) | 134 directory_files_internal_unwind (dh) |
135 Lisp_Object dh; | 135 Lisp_Object dh; |
136 { | 136 { |
137 DIR *d = (DIR *) XSAVE_VALUE (dh)->pointer; | 137 DIR *d = (DIR *) XSAVE_VALUE (dh)->pointer; |
138 BLOCK_INPUT; | |
138 closedir (d); | 139 closedir (d); |
140 UNBLOCK_INPUT; | |
139 return Qnil; | 141 return Qnil; |
140 } | 142 } |
141 | 143 |
142 /* Function shared by Fdirectory_files and Fdirectory_files_and_attributes. | 144 /* Function shared by Fdirectory_files and Fdirectory_files_and_attributes. |
143 When ATTRS is zero, return a list of directory filenames; when | 145 When ATTRS is zero, return a list of directory filenames; when |
195 encoded_directory = ENCODE_FILE (directory); | 197 encoded_directory = ENCODE_FILE (directory); |
196 | 198 |
197 /* Now *bufp is the compiled form of MATCH; don't call anything | 199 /* Now *bufp is the compiled form of MATCH; don't call anything |
198 which might compile a new regexp until we're done with the loop! */ | 200 which might compile a new regexp until we're done with the loop! */ |
199 | 201 |
202 BLOCK_INPUT; | |
200 d = opendir (SDATA (dirfilename)); | 203 d = opendir (SDATA (dirfilename)); |
204 UNBLOCK_INPUT; | |
201 if (d == NULL) | 205 if (d == NULL) |
202 report_file_error ("Opening directory", Fcons (directory, Qnil)); | 206 report_file_error ("Opening directory", Fcons (directory, Qnil)); |
203 | 207 |
204 /* Unfortunately, we can now invoke expand-file-name and | 208 /* Unfortunately, we can now invoke expand-file-name and |
205 file-attributes on filenames, both of which can throw, so we must | 209 file-attributes on filenames, both of which can throw, so we must |
320 | 324 |
321 UNGCPRO; | 325 UNGCPRO; |
322 } | 326 } |
323 } | 327 } |
324 | 328 |
329 BLOCK_INPUT; | |
325 closedir (d); | 330 closedir (d); |
331 UNBLOCK_INPUT; | |
326 | 332 |
327 /* Discard the unwind protect. */ | 333 /* Discard the unwind protect. */ |
328 specpdl_ptr = specpdl + count; | 334 specpdl_ptr = specpdl + count; |
329 | 335 |
330 if (NILP (nosort)) | 336 if (NILP (nosort)) |
507 | 513 |
508 for (passcount = !!all_flag; NILP (bestmatch) && passcount < 2; passcount++) | 514 for (passcount = !!all_flag; NILP (bestmatch) && passcount < 2; passcount++) |
509 { | 515 { |
510 int inner_count = SPECPDL_INDEX (); | 516 int inner_count = SPECPDL_INDEX (); |
511 | 517 |
518 BLOCK_INPUT; | |
512 d = opendir (SDATA (Fdirectory_file_name (encoded_dir))); | 519 d = opendir (SDATA (Fdirectory_file_name (encoded_dir))); |
520 UNBLOCK_INPUT; | |
513 if (!d) | 521 if (!d) |
514 report_file_error ("Opening directory", Fcons (dirname, Qnil)); | 522 report_file_error ("Opening directory", Fcons (dirname, Qnil)); |
515 | 523 |
516 record_unwind_protect (directory_files_internal_unwind, | 524 record_unwind_protect (directory_files_internal_unwind, |
517 make_save_value (d, 0)); | 525 make_save_value (d, 0)); |