diff options
author | Robin Watts <robin.watts@artifex.com> | 2013-05-21 19:29:34 +0100 |
---|---|---|
committer | Robin Watts <robin.watts@artifex.com> | 2013-05-21 19:34:00 +0100 |
commit | db9f1dadbc7c302bc6c1947760b95715dd1652e3 (patch) | |
tree | f9d51e8546ac610751b726a3f9b69009393eb396 /android/jni/mupdf.c | |
parent | f095f7ff494ae6c59dc72b5d4feeac5db5a27351 (diff) | |
download | mupdf-db9f1dadbc7c302bc6c1947760b95715dd1652e3.tar.xz |
Fix app breakages.
Android app was still thinking that we had only one fz_device_rgb rather
than one per context.
Android app had a typo in resulting in searching ending in an infinite
loop.
Text search failed to search outside the first block of each page.
Diffstat (limited to 'android/jni/mupdf.c')
-rw-r--r-- | android/jni/mupdf.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/android/jni/mupdf.c b/android/jni/mupdf.c index 8382c27c..f45e17ba 100644 --- a/android/jni/mupdf.c +++ b/android/jni/mupdf.c @@ -299,7 +299,7 @@ JNI_FN(MuPDFCore_openFile)(JNIEnv * env, jobject thiz, jstring jfilename) glo->doc = NULL; fz_try(ctx) { - glo->colorspace = fz_device_rgb; + glo->colorspace = fz_device_rgb(ctx); LOGE("Opening document..."); fz_try(ctx) @@ -418,7 +418,7 @@ JNI_FN(MuPDFCore_openBuffer)(JNIEnv * env, jobject thiz) stream = fz_new_stream(ctx, glo, bufferStreamRead, bufferStreamClose); stream->seek = bufferStreamSeek; - glo->colorspace = fz_device_rgb; + glo->colorspace = fz_device_rgb(ctx); LOGE("Opening document..."); fz_try(ctx) @@ -931,7 +931,7 @@ textlen(fz_text_page *page) int len = 0; int block_num; - for (block_num = 0; block_num < page->len; block_num) + for (block_num = 0; block_num < page->len; block_num++) { fz_text_block *block; fz_text_line *line; |