-/* $Id: man.c,v 1.37 2009/08/21 13:45:33 kristaps Exp $ */
+/* $Id: man.c,v 1.38 2009/08/22 08:56:16 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
break;
else if (' ' == buf[i])
break;
+
+ /* Check for invalid characters. */
+
+ if (isgraph((u_char)buf[i]))
+ continue;
+ return(man_perr(m, ln, i, WNPRINT));
}
mac[j] = 0;
-/* $Id: mdoc.c,v 1.103 2009/08/20 11:44:47 kristaps Exp $ */
+/* $Id: mdoc.c,v 1.104 2009/08/22 08:56:16 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009 Kristaps Dzonsons <kristaps@kth.se>
*
break;
else if (' ' == buf[i])
break;
+
+ /* Check for invalid characters. */
+
+ if (isgraph((u_char)buf[i]))
+ continue;
+ return(mdoc_perr(m, ln, i, EPRINT));
}
mac[j] = 0;