diff options
author | Tor Andersson <tor@ghostscript.com> | 2009-03-11 22:07:53 +0100 |
---|---|---|
committer | Tor Andersson <tor@ghostscript.com> | 2009-03-11 22:07:53 +0100 |
commit | 2e04ad6b587c9a34d18819165152ace7657cf443 (patch) | |
tree | 61fcaf8afa4509a38fd3deab41ad100ad6939cbe /fitz/res_font.c | |
parent | 9f6a77c2d17128a44bf2fc9fead449a05354def5 (diff) | |
download | mupdf-2e04ad6b587c9a34d18819165152ace7657cf443.tar.xz |
Remove fz_outofmem constant.
Diffstat (limited to 'fitz/res_font.c')
-rw-r--r-- | fitz/res_font.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/fitz/res_font.c b/fitz/res_font.c index 1261f2c4..00bb10d4 100644 --- a/fitz/res_font.c +++ b/fitz/res_font.c @@ -105,7 +105,7 @@ char *ft_errorstring(int err) return "Unknown error"; } -static fz_error +static fz_error fz_initfreetype(void) { int code; @@ -125,7 +125,7 @@ fz_initfreetype(void) return fz_okay; } -fz_error +fz_error fz_newfontfromfile(fz_font **fontp, char *path, int index) { fz_error error; @@ -138,7 +138,7 @@ fz_newfontfromfile(fz_font **fontp, char *path, int index) font = fz_newfont(); if (!font) - return fz_throw("outofmem: font struct"); + return fz_rethrow(-1, "out of memory: font struct"); code = FT_New_Face(fz_ftlib, path, index, (FT_Face*)&font->ftface); if (code) @@ -151,7 +151,7 @@ fz_newfontfromfile(fz_font **fontp, char *path, int index) return fz_okay; } -fz_error +fz_error fz_newfontfrombuffer(fz_font **fontp, unsigned char *data, int len, int index) { fz_error error; @@ -164,7 +164,7 @@ fz_newfontfrombuffer(fz_font **fontp, unsigned char *data, int len, int index) font = fz_newfont(); if (!font) - return fz_throw("outofmem: font struct"); + return fz_rethrow(-1, "out of memory: font struct"); code = FT_New_Memory_Face(fz_ftlib, data, len, index, (FT_Face*)&font->ftface); if (code) @@ -177,7 +177,7 @@ fz_newfontfrombuffer(fz_font **fontp, unsigned char *data, int len, int index) return fz_okay; } -fz_error +fz_error fz_renderftglyph(fz_glyph *glyph, fz_font *font, int gid, fz_matrix trm) { FT_Face face = font->ftface; @@ -299,7 +299,7 @@ fz_renderftglyph(fz_glyph *glyph, fz_font *font, int gid, fz_matrix trm) * Type 3 fonts... */ -fz_error +fz_error fz_newtype3font(fz_font **fontp, char *name, fz_matrix matrix) { fz_font *font; @@ -307,13 +307,13 @@ fz_newtype3font(fz_font **fontp, char *name, fz_matrix matrix) font = fz_newfont(); if (!font) - return fz_throw("outofmem: font struct"); + return fz_rethrow(-1, "out of memory: font struct"); font->t3procs = fz_malloc(sizeof(fz_tree*) * 256); if (!font->t3procs) { fz_free(font); - return fz_throw("outofmem: type3 font charproc array"); + return fz_rethrow(-1, "out of memory: type3 font charproc array"); } font->t3matrix = matrix; @@ -326,7 +326,7 @@ fz_newtype3font(fz_font **fontp, char *name, fz_matrix matrix) return fz_okay; } -fz_error +fz_error fz_rendert3glyph(fz_glyph *glyph, fz_font *font, int gid, fz_matrix trm) { fz_error error; |