Fixed incorrect type of variable ch_cur. It was from const char * but should have been const char.

This commit is contained in:
Jim Monte 2020-02-14 13:23:48 -05:00 committed by Holger Vogt
parent 9b4944df33
commit 38fb2e205f
1 changed files with 1 additions and 1 deletions

View File

@ -210,7 +210,7 @@ char *ngdirname(const char *name)
const char *p0 = name + start; /* 1st char past drive */
const char *p;
for (p = p0 + strlen(name + start) - 1; p >= p0; --p) {
const char *ch_cur = *p;
const char ch_cur = *p;
if (ch_cur == '/' || ch_cur == '\\') { /* at last dir sep */
/* Stop copy at last dir sep or right after if
* it is the first char after any drive spec.