]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
glib-2.0: Fix nullability in DirUtils mkdtemp and make_tmp
authorCorentin Noël <corentin.noel@collabora.com>
Thu, 6 Jul 2023 13:32:25 +0000 (15:32 +0200)
committerRico Tzschichholz <ricotz@ubuntu.com>
Thu, 6 Jul 2023 15:06:40 +0000 (17:06 +0200)
make_tmp uses a default template when used with NULL and mkdtemp can return
NULL with errno set.

vapi/glib-2.0.vapi

index 77675b67de6dbd959f33ff5f822cea12148a3189..ea4d7f2d3d9399da715a34ea1e95fa85496481c4 100644 (file)
@@ -4160,10 +4160,10 @@ namespace GLib {
                public static int create_with_parents (string pathname, int mode);
                [Version (since = "2.30")]
                [CCode (cname = "mkdtemp")]
-               public static string mkdtemp (owned string template);
+               public static string? mkdtemp (owned string template);
                [Version (since = "2.30")]
                [CCode (cname = "g_dir_make_tmp")]
-               public static string make_tmp (string tmpl) throws FileError;
+               public static string make_tmp (string? tmpl = null) throws FileError;
                [Version (since = "2.6")]
                [CCode (cname = "g_rmdir")]
                public static int remove (string filename);