Commit 66cb9c07 authored by Karl Heuer's avatar Karl Heuer

(x_create_bitmap_from_file): Fail immediately if magic.

parent f78643ef
...@@ -590,6 +590,9 @@ x_create_bitmap_from_file (f, file) ...@@ -590,6 +590,9 @@ x_create_bitmap_from_file (f, file)
fd = openp (Vx_bitmap_file_path, file, "", &found, 0); fd = openp (Vx_bitmap_file_path, file, "", &found, 0);
if (fd < 0) if (fd < 0)
return -1; return -1;
/* XReadBitmapFile won't handle magic file names. */
if (fd == 0)
return -1;
close (fd); close (fd);
filename = (char *) XSTRING (found)->data; filename = (char *) XSTRING (found)->data;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment