diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2016-11-28 12:15:17 +0100 |
---|---|---|
committer | Joseph Heenan <joseph@emobix.co.uk> | 2016-12-02 11:21:23 -0500 |
commit | e193755d37006064f7f625d87e4d602a6de89368 (patch) | |
tree | b1080957197f44c70c90833f469d42d9f6b8ea7e /platform | |
parent | d25a5d34fa9702167c6d758abcf0df22d96ce152 (diff) | |
download | mupdf-e193755d37006064f7f625d87e4d602a6de89368.tar.xz |
Fix iOS build.
Diffstat (limited to 'platform')
-rw-r--r-- | platform/ios/Classes/MuPageViewReflow.m | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/platform/ios/Classes/MuPageViewReflow.m b/platform/ios/Classes/MuPageViewReflow.m index c5963f2f..f58bf72f 100644 --- a/platform/ios/Classes/MuPageViewReflow.m +++ b/platform/ios/Classes/MuPageViewReflow.m @@ -12,6 +12,8 @@ NSString *textAsHtml(fz_document *doc, int pageNum) fz_buffer *buf = NULL; fz_output *out = NULL; fz_rect mediabox; + size_t len; + unsigned char *data; fz_var(page); fz_var(sheet); @@ -55,7 +57,8 @@ NSString *textAsHtml(fz_document *doc, int pageNum) out = NULL; - str = [[[NSString alloc] initWithBytes:buf->data length:buf->len encoding:NSUTF8StringEncoding] autorelease]; + len = fz_buffer_storage(ctx, buf, &data); + str = [[[NSString alloc] initWithBytes:data length:len encoding:NSUTF8StringEncoding] autorelease]; } fz_always(ctx) { |