-diff --git a/pdf/pdf_font.c b/pdf/pdf_font.c
-index 33a1a65..c2fdee3 100644
---- a/pdf/pdf_font.c
-+++ b/pdf/pdf_font.c
+diff --git a/source/pdf/pdf-font.c b/source/pdf/pdf-font.c
+index f79a076..4ecb159 100644
+--- a/source/pdf/pdf-font.c
++++ b/source/pdf/pdf-font.c
 @@ -185,7 +185,12 @@ pdf_load_builtin_font(fz_context *ctx, pdf_font_desc *fontdesc, char *fontname)
  	if (!data)
- 		fz_throw(ctx, "cannot find builtin font: '%s'", fontname);
+ 		fz_throw(ctx, FZ_ERROR_GENERIC, "cannot find builtin font: '%s'", fontname);
  
 +#ifndef NOBUILTINFONT
  	fontdesc->font = fz_new_font_from_memory(ctx, fontname, data, len, 0, 1);

 #ifdef NOCJK
 #define NOCJKFONT
 #endif
@@ -152,3 +154,112 @@ pdf_lookup_substitute_cjk_font(int ros, int serif, unsigned int *len)
 	return NULL;
 #endif
 }

 
 	fontdesc->font->ft_substitute = 1;
 }
diff --git a/source/pdf/pdf-fontfile.c b/source/pdf/pdf-fontfile.c
index c9990da..9c091a7 100644
--- a/source/pdf/pdf-fontfile.c
+++ b/source/pdf/pdf-fontfile.c
@@ -14,6 +14,8 @@
 	Set NODROIDFONT to use the base 14 fonts as substitute fonts.
 */
 
