/* everything up to the first '-' is in the name */
while (*pstr) {
+ if (*pstr == '\'' || !isgraph(*pstr)) {
+ return 0;
+ }
if (*pstr == '-' && isdigit(*(pstr+1))) {
break;
}
pstr++;
}
while (*pstr && *pstr != '-') {
+ if (*pstr == '\'' || !isgraph(*pstr)) {
+ return 0;
+ }
if (ver) {
*ver++ = *pstr;
}