diff options
author | Sebastian Rasmussen <sebras@gmail.com> | 2012-08-06 11:50:48 +0200 |
---|---|---|
committer | Sebastian Rasmussen <sebras@gmail.com> | 2012-08-06 14:06:44 +0200 |
commit | 9406ed183d4f1b1bb2b44eee08dce751f0f15345 (patch) | |
tree | 40703a828bbf5b216b1c59b7b4e8ccc925f44b02 | |
parent | a0cbb73ccb175d5f89ff72f205187ac93623f6af (diff) | |
download | mupdf-9406ed183d4f1b1bb2b44eee08dce751f0f15345.tar.xz |
Make fz_open_file_*() always throw exceptions upon error
Thanks to Zeniko for pointing out the inconsistency.
-rw-r--r-- | fitz/stm_open.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/fitz/stm_open.c b/fitz/stm_open.c index 1709340b..3d605e1a 100644 --- a/fitz/stm_open.c +++ b/fitz/stm_open.c @@ -140,7 +140,7 @@ fz_open_file_w(fz_context *ctx, const wchar_t *name) { int fd = _wopen(name, O_BINARY | O_RDONLY, 0); if (fd == -1) - return NULL; + fz_throw(ctx, "cannot open file %Ls", name); return fz_open_fd(ctx, fd); } #endif |