---
 texk/dvipdfm-x/dvi.c |   31 +++++++++++++++++++++++++++++++
 1 file changed, 31 insertions(+)

--- texlive-bin.orig/texk/dvipdfm-x/dvi.c
+++ texlive-bin/texk/dvipdfm-x/dvi.c
@@ -921,6 +921,34 @@
 
 #ifdef XETEX
 static int
+is_notdef_notzero (char *path)
+{
+  FILE *f;
+  char buf[2014];
+  char cmd[512];
+  char *p;
+  int  ret = 0;
+
+  strcpy (cmd, "t1disasm ");
+  strcat (cmd, path);
+  f = popen (cmd, "r");
+  if (f) {
+    while ((fgets (buf, 2000, f))) {
+      p = strstr (buf, "CharStrings");
+      if (p) {
+        fgets (buf, 2000, f);
+        if (strncmp (buf, "/.notdef", 8) != 0)
+          ret = 1;
+        break;
+      }
+    }
+    fclose(f);
+  }
+
+  return ret;
+}
+
+static int
 dvi_locate_native_font (const char *filename, uint32_t index,
                         spt_t ptsize, int layout_dir, int extend, int slant, int embolden)
 {
@@ -1000,6 +1028,9 @@
     loaded_fonts[cur_id].numGlyphs = cffont->num_glyphs;
 
     DPXFCLOSE(fp);
+    if (loaded_fonts[cur_id].cff_is_standard_encoding) {
+      loaded_fonts[cur_id].cff_is_standard_encoding = is_notdef_notzero (path);
+    }
   } else {
     if (is_dfont)
       sfont = dfont_open(fp, index);
