diff options
| author | Miles Bader | 2000-11-13 12:24:15 +0000 |
|---|---|---|
| committer | Miles Bader | 2000-11-13 12:24:15 +0000 |
| commit | 939d6465fc54ccd74381dae6bba1dd416928e8b8 (patch) | |
| tree | 7fae9e0660113787fa9352b0c3568ebb48fce711 /src | |
| parent | 96dc0f4e12535b038c0f87838a03029a3ebb20fa (diff) | |
| download | emacs-939d6465fc54ccd74381dae6bba1dd416928e8b8.tar.gz emacs-939d6465fc54ccd74381dae6bba1dd416928e8b8.zip | |
(x_create_bitmap_from_file, x_find_image_file): Use new openp return protocol.
Diffstat (limited to 'src')
| -rw-r--r-- | src/w32fns.c | 5 | ||||
| -rw-r--r-- | src/xfns.c | 5 |
2 files changed, 2 insertions, 8 deletions
diff --git a/src/w32fns.c b/src/w32fns.c index a0bd2b67451..4ff6065ef60 100644 --- a/src/w32fns.c +++ b/src/w32fns.c | |||
| @@ -584,9 +584,6 @@ x_create_bitmap_from_file (f, file) | |||
| 584 | fd = openp (Vx_bitmap_file_path, file, "", &found, 0); | 584 | fd = openp (Vx_bitmap_file_path, file, "", &found, 0); |
| 585 | if (fd < 0) | 585 | if (fd < 0) |
| 586 | return -1; | 586 | return -1; |
| 587 | /* LoadLibraryEx won't handle special files handled by Emacs handler. */ | ||
| 588 | if (fd == 0) | ||
| 589 | return -1; | ||
| 590 | emacs_close (fd); | 587 | emacs_close (fd); |
| 591 | 588 | ||
| 592 | filename = (char *) XSTRING (found)->data; | 589 | filename = (char *) XSTRING (found)->data; |
| @@ -8377,7 +8374,7 @@ x_find_image_file (file) | |||
| 8377 | /* Try to find FILE in data-directory, then x-bitmap-file-path. */ | 8374 | /* Try to find FILE in data-directory, then x-bitmap-file-path. */ |
| 8378 | fd = openp (search_path, file, "", &file_found, 0); | 8375 | fd = openp (search_path, file, "", &file_found, 0); |
| 8379 | 8376 | ||
| 8380 | if (fd < 0) | 8377 | if (fd == -1) |
| 8381 | file_found = Qnil; | 8378 | file_found = Qnil; |
| 8382 | else | 8379 | else |
| 8383 | close (fd); | 8380 | close (fd); |
diff --git a/src/xfns.c b/src/xfns.c index 2b5ff4cc9fa..1a45b20c984 100644 --- a/src/xfns.c +++ b/src/xfns.c | |||
| @@ -663,9 +663,6 @@ x_create_bitmap_from_file (f, file) | |||
| 663 | fd = openp (Vx_bitmap_file_path, file, "", &found, 0); | 663 | fd = openp (Vx_bitmap_file_path, file, "", &found, 0); |
| 664 | if (fd < 0) | 664 | if (fd < 0) |
| 665 | return -1; | 665 | return -1; |
| 666 | /* XReadBitmapFile won't handle magic file names. */ | ||
| 667 | if (fd == 0) | ||
| 668 | return -1; | ||
| 669 | emacs_close (fd); | 666 | emacs_close (fd); |
| 670 | 667 | ||
| 671 | filename = (char *) XSTRING (found)->data; | 668 | filename = (char *) XSTRING (found)->data; |
| @@ -6110,7 +6107,7 @@ x_find_image_file (file) | |||
| 6110 | /* Try to find FILE in data-directory, then x-bitmap-file-path. */ | 6107 | /* Try to find FILE in data-directory, then x-bitmap-file-path. */ |
| 6111 | fd = openp (search_path, file, "", &file_found, 0); | 6108 | fd = openp (search_path, file, "", &file_found, 0); |
| 6112 | 6109 | ||
| 6113 | if (fd < 0) | 6110 | if (fd == -1) |
| 6114 | file_found = Qnil; | 6111 | file_found = Qnil; |
| 6115 | else | 6112 | else |
| 6116 | close (fd); | 6113 | close (fd); |