comparison src/dired-msw.c @ 2526:902d5bd9b75c

[xemacs-hg @ 2005-01-28 02:36:11 by ben] Support symlinks under Windows nt.c, fileio.c: Fix sync comments. config.h.in, dired-msw.c, emacs.c, event-msw.c, fileio.c, glyphs.c, lisp.h, nt.c, process-nt.c, realpath.c, sound.c, symsinit.h, sysdep.c, sysfile.h, syswindows.h, win32.c: Add support for treating shortcuts under Windows as symbolic links. Enabled with mswindows-shortcuts-are-links (t by default). Rewrite lots of places to use PATHNAME_CONVERT_OUT, which is moved to sysfile.h. Add PATHNAME_RESOLVE_LINKS, which only does things under Windows. Add profiling section for expand_file_name calls. nt.c, sysdep.c: Unicode-ize. realpath.c: Renamed from readlink_and_correct_case. Fix some problems with Windows implementation due to incorrect understanding of workings of the function. sound.c, ntplay.c, sound.h: Rename play_sound_file to nt_play_sound_file and pass internally-formatted data to it to avoid converting out and back again. text.h: is_c -> is_ascii.
author ben
date Fri, 28 Jan 2005 02:36:28 +0000
parents ab71ad6ff3dd
children 0d4c9d0f6a8d
comparison
equal deleted inserted replaced
2525:52f00344a629 2526:902d5bd9b75c
190 Win32_file_dynarr *files = Dynarr_new (Win32_file); 190 Win32_file_dynarr *files = Dynarr_new (Win32_file);
191 struct re_pattern_buffer *bufp = NULL; 191 struct re_pattern_buffer *bufp = NULL;
192 int findex; 192 int findex;
193 DECLARE_EISTRING (win32pattern); 193 DECLARE_EISTRING (win32pattern);
194 HANDLE fh; 194 HANDLE fh;
195 int errm; 195 int errm;
196 196
197 while (1) 197 while (1)
198 { 198 {
199 if (!NILP (pattern)) 199 if (!NILP (pattern))
200 { 200 {
204 bufp = compile_pattern (pattern, 0, Qnil, Qnil, 0, 0, ERROR_ME); 204 bufp = compile_pattern (pattern, 0, Qnil, Qnil, 0, 0, ERROR_ME);
205 } 205 }
206 /* Now *bufp is the compiled form of PATTERN; don't call anything 206 /* Now *bufp is the compiled form of PATTERN; don't call anything
207 which might compile a new regexp until we're done with the loop! */ 207 which might compile a new regexp until we're done with the loop! */
208 208
209 {
210 Ibyte *dir2;
211 LISP_PATHNAME_RESOLVE_LINKS (dirfile, dir2);
212 eicpy_rawz (win32pattern, dir2);
213 }
214
209 /* for Win32, we need to insure that the pathname ends with "\*". */ 215 /* for Win32, we need to insure that the pathname ends with "\*". */
210 eicpy_lstr (win32pattern, dirfile);
211 if (!nowild) 216 if (!nowild)
212 { 217 {
213 Charcount len = eicharlen (win32pattern) - 1; 218 Charcount len = eicharlen (win32pattern) - 1;
214 if (!IS_DIRECTORY_SEP (eigetch_char (win32pattern, len))) 219 if (!IS_DIRECTORY_SEP (eigetch_char (win32pattern, len)))
215 eicat_ascii (win32pattern, "\\"); 220 eicat_ascii (win32pattern, "\\");