mirror of
https://gitlab.freedesktop.org/libinput/libinput.git
synced 2025-12-26 15:40:06 +01:00
util: fix error in mkdir_p if a parent directory fails to be created
Part-of: <https://gitlab.freedesktop.org/libinput/libinput/-/merge_requests/984>
This commit is contained in:
parent
9c69152428
commit
d6e54c3597
1 changed files with 3 additions and 1 deletions
|
|
@ -43,7 +43,9 @@ mkdir_p(const char *dir)
|
|||
path = safe_strdup(dir);
|
||||
parent = dirname(path);
|
||||
|
||||
mkdir_p(parent);
|
||||
if ((rc = mkdir_p(parent)) < 0)
|
||||
return rc;
|
||||
|
||||
rc = mkdir(dir, 0755);
|
||||
|
||||
free(path);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue