+ if (BACKSLASH_IS_PATH_SEPARATOR)
+ {
+ char *b = strrchr (path, '\\');
+ if (b && slash < b)
+ slash = b;
+ }
+
+ /* Make sure there are no trailing slashes. */
+ assert (slash == NULL /* There are no slashes in PATH. */
+ || slash[1] != 0 /* There is a non-NUL byte after the last slash. */
+ || path == slash /* PATH is just `/'. */
+ );
+