diff options
author | Jason Rumney <[email protected]> | 2007-11-19 09:14:38 +0000 |
---|---|---|
committer | Jason Rumney <[email protected]> | 2007-11-19 09:14:38 +0000 |
commit | 5f42a7eba296b36aa62f9a6019928fd313020ec3 (patch) | |
tree | 4988be5614aa040845642fa1424137d89ceeff4a /src/w32bdf.c | |
parent | 1030a7b3f86fe3b4dbe4f6d30bd0dc7a8ccb33c8 (diff) |
(w32_init_bdf_font, w32_BDF_to_x_font): CreateFileMapping
returns NULL on failure.
Diffstat (limited to 'src/w32bdf.c')
-rw-r--r-- | src/w32bdf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/w32bdf.c b/src/w32bdf.c index 80ef098d8d..4a12b1f019 100644 --- a/src/w32bdf.c +++ b/src/w32bdf.c @@ -261,7 +261,7 @@ w32_init_bdf_font(char *filename) error("Fail to open BDF file"); } hfilemap = CreateFileMapping(hfile, NULL, PAGE_READONLY, 0, 0, NULL); - if (hfilemap == INVALID_HANDLE_VALUE) + if (!hfilemap) { CloseHandle(hfile); error("Can't map font"); @@ -828,7 +828,7 @@ int w32_BDF_to_x_font (char *file, char* xstr, int len) size = fileinfo.nFileSizeLow; hfilemap = CreateFileMapping (hfile, NULL, PAGE_READONLY, 0, 0, NULL); - if (hfilemap == INVALID_HANDLE_VALUE) + if (!hfilemap) { CloseHandle (hfile); return 0; |