mirror of
https://gitlab.gnome.org/GNOME/glib.git
synced 2025-08-12 12:14:06 +02:00
girparser: Make ownership transfers out of locate_gir() more obvious
Signed-off-by: Simon McVittie <smcv@debian.org>
This commit is contained in:
committed by
Simon McVittie
parent
79e1bc5bef
commit
9d8bcc9817
@@ -303,7 +303,7 @@ locate_gir (GIrParser *parser,
|
|||||||
path = g_build_filename (*dir, girname, NULL);
|
path = g_build_filename (*dir, girname, NULL);
|
||||||
g_debug ("Trying %s from includes", path);
|
g_debug ("Trying %s from includes", path);
|
||||||
if (g_file_test (path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR))
|
if (g_file_test (path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR))
|
||||||
return path;
|
return g_steal_pointer (&path);
|
||||||
g_free (path);
|
g_free (path);
|
||||||
path = NULL;
|
path = NULL;
|
||||||
}
|
}
|
||||||
@@ -313,7 +313,7 @@ locate_gir (GIrParser *parser,
|
|||||||
path = g_build_filename (*dir, GIR_SUFFIX, girname, NULL);
|
path = g_build_filename (*dir, GIR_SUFFIX, girname, NULL);
|
||||||
g_debug ("Trying %s from system data dirs", path);
|
g_debug ("Trying %s from system data dirs", path);
|
||||||
if (g_file_test (path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR))
|
if (g_file_test (path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR))
|
||||||
return path;
|
return g_steal_pointer (&path);
|
||||||
g_free (path);
|
g_free (path);
|
||||||
path = NULL;
|
path = NULL;
|
||||||
}
|
}
|
||||||
@@ -321,7 +321,7 @@ locate_gir (GIrParser *parser,
|
|||||||
path = g_build_filename (GIR_DIR, girname, NULL);
|
path = g_build_filename (GIR_DIR, girname, NULL);
|
||||||
g_debug ("Trying %s from GIR_DIR", path);
|
g_debug ("Trying %s from GIR_DIR", path);
|
||||||
if (g_file_test (path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR))
|
if (g_file_test (path, G_FILE_TEST_EXISTS | G_FILE_TEST_IS_REGULAR))
|
||||||
return path;
|
return g_steal_pointer (&path);
|
||||||
g_free (path);
|
g_free (path);
|
||||||
|
|
||||||
g_debug ("Did not find %s", girname);
|
g_debug ("Did not find %s", girname);
|
||||||
|
Reference in New Issue
Block a user