mirror of
https://git.do.srb2.org/STJr/SRB2.git
synced 2025-01-18 07:22:28 +00:00
Fix M_PathParts instead
This commit is contained in:
parent
3bb7fd4cbf
commit
244f0b228f
2 changed files with 5 additions and 6 deletions
|
@ -2457,6 +2457,8 @@ int M_PathParts(const char *path)
|
|||
int n;
|
||||
const char *p;
|
||||
const char *t;
|
||||
if (path == NULL)
|
||||
return 0;
|
||||
for (n = 0, p = path ;; ++n)
|
||||
{
|
||||
t = p;
|
||||
|
|
|
@ -197,12 +197,9 @@ int main(int argc, char **argv)
|
|||
format, timeinfo);
|
||||
}
|
||||
|
||||
if (logdir)
|
||||
{
|
||||
M_MkdirEachUntil(logfilename,
|
||||
M_PathParts(logdir) - 1,
|
||||
M_PathParts(logfilename) - 1, 0755);
|
||||
}
|
||||
|
||||
#ifdef __unix__
|
||||
logstream = fopen(logfilename, "w");
|
||||
|
|
Loading…
Reference in a new issue