(Fnew_fontset): Check NAME more rigidly.
authorKenichi Handa <handa@m17n.org>
Thu, 23 Oct 2003 08:42:39 +0000 (08:42 +0000)
committerKenichi Handa <handa@m17n.org>
Thu, 23 Oct 2003 08:42:39 +0000 (08:42 +0000)
src/fontset.c

index 82628c2..5193848 100644 (file)
@@ -1378,7 +1378,7 @@ FONT-SPEC is a vector, a cons, or a string.  See the documentation of
     {
       name = Fdowncase (name);
       val = split_font_name_into_vector (name);
-      if (NILP (val))
+      if (NILP (val) || NILP (AREF (val, 12)) || NILP (AREF (val, 13)))
        error ("Fontset name must be in XLFD format");
       if (strcmp (SDATA (AREF (val, 12)), "fontset"))
        error ("Registry field of fontset name must be \"fontset\"");