aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorStefan Monnier2001-10-12 03:37:43 +0000
committerStefan Monnier2001-10-12 03:37:43 +0000
commitc0ec53ad99ba41fca0f34440c232c8ad203f4259 (patch)
treecad8633f767ceaed67cf3788e59e21c344ea695d /src
parentb81a1b72a82185bc426d31f914a5d3d7fee14c4e (diff)
downloademacs-c0ec53ad99ba41fca0f34440c232c8ad203f4259.tar.gz
emacs-c0ec53ad99ba41fca0f34440c232c8ad203f4259.zip
Update calls to openp.
Diffstat (limited to 'src')
-rw-r--r--src/ChangeLog21
-rw-r--r--src/emacs.c2
-rw-r--r--src/process.c6
-rw-r--r--src/sound.c2
-rw-r--r--src/w32.c2
-rw-r--r--src/w32fns.c4
-rw-r--r--src/w32proc.c2
-rw-r--r--src/xfns.c8
8 files changed, 34 insertions, 13 deletions
diff --git a/src/ChangeLog b/src/ChangeLog
index 7ee74db35e8..4bf6ae794e2 100644
--- a/src/ChangeLog
+++ b/src/ChangeLog
@@ -1,8 +1,29 @@
12001-10-11 Stefan Monnier <monnier@cs.yale.edu> 12001-10-11 Stefan Monnier <monnier@cs.yale.edu>
2 2
3 * xfns.c (x_create_bitmap_from_file, x_find_image_file):
4 * w32proc.c (sys_spawnve):
5 * w32fns.c (x_create_bitmap_from_file, x_find_image_file):
6 * w32.c (check_windows_init_file):
7 * sound.c (Fplay_sound):
8 * process.c (Fstart_process): Update calls to openp.
9
10 * callproc.c (Vexec_suffixes): New var.
11 (Fcall_process): Update call to openp.
12 (decode_suffixes): New function.
13 (syms_of_callproc): Init exec-suffixes.
14
15 * lread.c (Vload_suffixes, default_suffixes): New vars.
16 (openp): Take a lisp list of suffixes.
17 Check for file-name-handlers even if the file was absolute already.
18 (syms_of_lread): Declare load-suffixes.
19 (Fload): Fix up call to openp.
20 Don't bother checking for file-name-handler at the very beginning.
21
3 * keymap.h (Fcopy_keymap): Don't export. 22 * keymap.h (Fcopy_keymap): Don't export.
4 23
5 * lisp.h (empty_string): Declare. 24 * lisp.h (empty_string): Declare.
25 (Vload_suffixes, Vexec_suffixes): Declare.
26 (openp): Update prototype.
6 27
7 * emacs.c (empty_string): New var. 28 * emacs.c (empty_string): New var.
8 (syms_of_emacs): Initialize it. 29 (syms_of_emacs): Initialize it.
diff --git a/src/emacs.c b/src/emacs.c
index f79b094f93a..64446fecb2b 100644
--- a/src/emacs.c
+++ b/src/emacs.c
@@ -438,7 +438,7 @@ init_cmdargs (argc, argv, skip_args)
438 { 438 {
439 Lisp_Object found; 439 Lisp_Object found;
440 int yes = openp (Vexec_path, Vinvocation_name, 440 int yes = openp (Vexec_path, Vinvocation_name,
441 EXEC_SUFFIXES, &found, 1); 441 Vexec_suffixes, &found, 1);
442 if (yes == 1) 442 if (yes == 1)
443 { 443 {
444 /* Add /: to the front of the name 444 /* Add /: to the front of the name
diff --git a/src/process.c b/src/process.c
index 474b21f2476..d9eab3f097b 100644
--- a/src/process.c
+++ b/src/process.c
@@ -1196,7 +1196,7 @@ Remaining arguments are strings to give program as arguments.")
1196 1196
1197 tem = Qnil; 1197 tem = Qnil;
1198 GCPRO4 (name, program, buffer, current_dir); 1198 GCPRO4 (name, program, buffer, current_dir);
1199 openp (Vexec_path, program, EXEC_SUFFIXES, &tem, 1); 1199 openp (Vexec_path, program, Vexec_suffixes, &tem, 1);
1200 UNGCPRO; 1200 UNGCPRO;
1201 if (NILP (tem)) 1201 if (NILP (tem))
1202 report_file_error ("Searching for program", Fcons (program, Qnil)); 1202 report_file_error ("Searching for program", Fcons (program, Qnil));
@@ -3386,8 +3386,8 @@ send_process (proc, buf, len, object)
3386 Long lines need to be split into multiple batches. */ 3386 Long lines need to be split into multiple batches. */
3387 if (!NILP (XPROCESS (proc)->pty_flag)) 3387 if (!NILP (XPROCESS (proc)->pty_flag))
3388 { 3388 {
3389 /* Starting this at zero is always correct when not the first iteration 3389 /* Starting this at zero is always correct when not the first
3390 because the previous iteration ended by sending C-d. 3390 iteration because the previous iteration ended by sending C-d.
3391 It may not be correct for the first iteration 3391 It may not be correct for the first iteration
3392 if a partial line was sent in a separate send_process call. 3392 if a partial line was sent in a separate send_process call.
3393 If that proves worth handling, we need to save linepos 3393 If that proves worth handling, we need to save linepos
diff --git a/src/sound.c b/src/sound.c
index 1c2d59e05b6..2a7be3ea86d 100644
--- a/src/sound.c
+++ b/src/sound.c
@@ -412,7 +412,7 @@ a system-dependent default device name is used.")
412 { 412 {
413 /* Open the sound file. */ 413 /* Open the sound file. */
414 s.fd = openp (Fcons (Vdata_directory, Qnil), 414 s.fd = openp (Fcons (Vdata_directory, Qnil),
415 attrs[SOUND_FILE], "", &file, 0); 415 attrs[SOUND_FILE], Qnil, &file, 0);
416 if (s.fd < 0) 416 if (s.fd < 0)
417 sound_perror ("Open sound file"); 417 sound_perror ("Open sound file");
418 418
diff --git a/src/w32.c b/src/w32.c
index 3703347d810..dbdd13d4d33 100644
--- a/src/w32.c
+++ b/src/w32.c
@@ -3329,7 +3329,7 @@ check_windows_init_file ()
3329 objs[1] = decode_env_path (0, (getenv ("EMACSLOADPATH"))); 3329 objs[1] = decode_env_path (0, (getenv ("EMACSLOADPATH")));
3330 full_load_path = Fappend (2, objs); 3330 full_load_path = Fappend (2, objs);
3331 init_file = build_string ("term/w32-win"); 3331 init_file = build_string ("term/w32-win");
3332 fd = openp (full_load_path, init_file, ".el:.elc", NULL, 0); 3332 fd = openp (full_load_path, init_file, Vload_suffixes, NULL, 0);
3333 if (fd < 0) 3333 if (fd < 0)
3334 { 3334 {
3335 Lisp_Object load_path_print = Fprin1_to_string (full_load_path, Qnil); 3335 Lisp_Object load_path_print = Fprin1_to_string (full_load_path, Qnil);
diff --git a/src/w32fns.c b/src/w32fns.c
index 5173a25fe93..f1884e0f4e5 100644
--- a/src/w32fns.c
+++ b/src/w32fns.c
@@ -551,7 +551,7 @@ x_create_bitmap_from_file (f, file)
551 } 551 }
552 552
553 /* Search bitmap-file-path for the file, if appropriate. */ 553 /* Search bitmap-file-path for the file, if appropriate. */
554 fd = openp (Vx_bitmap_file_path, file, "", &found, 0); 554 fd = openp (Vx_bitmap_file_path, file, Qnil, &found, 0);
555 if (fd < 0) 555 if (fd < 0)
556 return -1; 556 return -1;
557 emacs_close (fd); 557 emacs_close (fd);
@@ -8654,7 +8654,7 @@ x_find_image_file (file)
8654 GCPRO2 (file_found, search_path); 8654 GCPRO2 (file_found, search_path);
8655 8655
8656 /* Try to find FILE in data-directory, then x-bitmap-file-path. */ 8656 /* Try to find FILE in data-directory, then x-bitmap-file-path. */
8657 fd = openp (search_path, file, "", &file_found, 0); 8657 fd = openp (search_path, file, Qnil, &file_found, 0);
8658 8658
8659 if (fd == -1) 8659 if (fd == -1)
8660 file_found = Qnil; 8660 file_found = Qnil;
diff --git a/src/w32proc.c b/src/w32proc.c
index 8d5890b86dd..d2eb38fbfbd 100644
--- a/src/w32proc.c
+++ b/src/w32proc.c
@@ -744,7 +744,7 @@ sys_spawnve (int mode, char *cmdname, char **argv, char **envp)
744 744
745 full = Qnil; 745 full = Qnil;
746 GCPRO1 (program); 746 GCPRO1 (program);
747 openp (Vexec_path, program, EXEC_SUFFIXES, &full, 1); 747 openp (Vexec_path, program, Vexec_suffixes, &full, 1);
748 UNGCPRO; 748 UNGCPRO;
749 if (NILP (full)) 749 if (NILP (full))
750 { 750 {
diff --git a/src/xfns.c b/src/xfns.c
index c28a2f801eb..f08dddaad6e 100644
--- a/src/xfns.c
+++ b/src/xfns.c
@@ -641,7 +641,7 @@ x_create_bitmap_from_file (f, file)
641 } 641 }
642 642
643 /* Search bitmap-file-path for the file, if appropriate. */ 643 /* Search bitmap-file-path for the file, if appropriate. */
644 fd = openp (Vx_bitmap_file_path, file, "", &found, 0); 644 fd = openp (Vx_bitmap_file_path, file, Qnil, &found, 0);
645 if (fd < 0) 645 if (fd < 0)
646 return -1; 646 return -1;
647 emacs_close (fd); 647 emacs_close (fd);
@@ -2970,9 +2970,9 @@ x_default_scroll_bar_color_parameter (f, alist, prop, xprop, xclass,
2970 build_string (foreground_p 2970 build_string (foreground_p
2971 ? "foreground" 2971 ? "foreground"
2972 : "background"), 2972 : "background"),
2973 build_string (""), 2973 empty_string,
2974 build_string ("verticalScrollBar"), 2974 build_string ("verticalScrollBar"),
2975 build_string ("")); 2975 empty_string);
2976 if (!STRINGP (tem)) 2976 if (!STRINGP (tem))
2977 { 2977 {
2978 /* If nothing has been specified, scroll bars will use a 2978 /* If nothing has been specified, scroll bars will use a
@@ -6359,7 +6359,7 @@ x_find_image_file (file)
6359 GCPRO2 (file_found, search_path); 6359 GCPRO2 (file_found, search_path);
6360 6360
6361 /* Try to find FILE in data-directory, then x-bitmap-file-path. */ 6361 /* Try to find FILE in data-directory, then x-bitmap-file-path. */
6362 fd = openp (search_path, file, "", &file_found, 0); 6362 fd = openp (search_path, file, Qnil, &file_found, 0);
6363 6363
6364 if (fd == -1) 6364 if (fd == -1)
6365 file_found = Qnil; 6365 file_found = Qnil;