Don't use the side effect of ++var, just use the result

git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@23659 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
Love Hörnquist Åstrand
2008-08-25 02:30:04 +00:00
parent c5b7d0e858
commit cf152f04f1

View File

@@ -113,7 +113,7 @@ static int SplitPath(char *path, char **dirpart, char **filepart)
if ((dpart = strdup(path)) == NULL)
return -1;
dpart[fpart - path] = '\0';
if ((fpart = strdup(++fpart)) == NULL) {
if ((fpart = strdup(fpart + 1)) == NULL) {
free(dpart);
return -1;
}