comparison src/xfns.c @ 33443:2c60aa5cd386

(x_create_bitmap_from_file, x_find_image_file): Use new openp return protocol.
author Miles Bader <miles@gnu.org>
date Mon, 13 Nov 2000 12:24:15 +0000
parents 421e3db4e24e
children 5832e9020859
comparison
equal deleted inserted replaced
33442:ec5c714ae981 33443:2c60aa5cd386
660 } 660 }
661 661
662 /* Search bitmap-file-path for the file, if appropriate. */ 662 /* Search bitmap-file-path for the file, if appropriate. */
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;
666 /* XReadBitmapFile won't handle magic file names. */
667 if (fd == 0)
668 return -1; 665 return -1;
669 emacs_close (fd); 666 emacs_close (fd);
670 667
671 filename = (char *) XSTRING (found)->data; 668 filename = (char *) XSTRING (found)->data;
672 669
6108 GCPRO2 (file_found, search_path); 6105 GCPRO2 (file_found, search_path);
6109 6106
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);
6117 6114
6118 UNGCPRO; 6115 UNGCPRO;