--- pathchk.c.orig 2012-03-12 23:37:55.000000000 +0100 +++ pathchk.c 2012-03-12 23:39:24.000000000 +0100 @@ -142,7 +142,7 @@ goto bad; } - if (pflag && (badch = portable(p)) >= 0) { + if (pflag && (badch = portable(p)) != 0) { warnx("%s: %s: component contains non-portable " "character `%c'", path, p, badch); goto bad; @@ -201,5 +201,5 @@ if (path[s] != '\0') return (path[s]); printf("bar:%s\n",path); - return (-1); + return (0); }