core: One more minor tweak to recursive directory creation
We would fail in the case where we were trying to create a subdirectory of /; this didn't actually happen, just noticed via code inspection.
This commit is contained in:
parent
a284075731
commit
c159188b81
|
|
@ -71,11 +71,9 @@ ot_gfile_ensure_directory (GFile *dir,
|
||||||
{
|
{
|
||||||
if (!ot_gfile_ensure_directory (parent, TRUE, error))
|
if (!ot_gfile_ensure_directory (parent, TRUE, error))
|
||||||
goto out;
|
goto out;
|
||||||
if (!g_file_make_directory (dir, NULL, error))
|
|
||||||
goto out;
|
|
||||||
}
|
}
|
||||||
else
|
if (!g_file_make_directory (dir, NULL, error))
|
||||||
g_assert_not_reached ();
|
goto out;
|
||||||
}
|
}
|
||||||
else if (!g_error_matches (temp_error, G_IO_ERROR, G_IO_ERROR_EXISTS))
|
else if (!g_error_matches (temp_error, G_IO_ERROR, G_IO_ERROR_EXISTS))
|
||||||
{
|
{
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue