]> git.ipfire.org Git - thirdparty/vala.git/commitdiff
zlib: Fix dest length argument for Utility.compress and uncompress.
authorBianShaoLei <bianshaolei@gmail.com>
Mon, 19 Jul 2010 08:33:26 +0000 (01:33 -0700)
committerEvan Nemerson <evan@coeus-group.com>
Mon, 19 Jul 2010 08:33:26 +0000 (01:33 -0700)
Fixes bug 623088.

vapi/zlib.vapi

index d27555b0ef5d5f77ee77e29a394a572a556563a2..1dd5ac688d47d01175da5de74801f6c68f17f9b1 100644 (file)
@@ -144,10 +144,10 @@ namespace ZLib {
        [CCode (lower_case_cprefix = "")]
        namespace Utility {
                [CCode (cname = "compress2")]
-               public static int compress ([CCode (array_length_type = "gulong")] uchar[] dest, [CCode (array_length_type = "gulong")] uchar[] source, int level = Level.DEFAULT_COMPRESSION);
+               public static int compress ([CCode (array_length = false)] uchar[] dest, ref ulong dest_length, [CCode (array_length_type = "gulong")] uchar[] source, int level = Level.DEFAULT_COMPRESSION);
                [CCode (cname = "compressBound")]
                public static int compress_bound (ulong sourceLen);
-               public static int uncompress ([CCode (array_length_type = "gulong")] uchar[] dest, [CCode (array_length_type = "gulong")] uchar[] source);
+               public static int uncompress ([CCode (array_length = false)] uchar[] dest, ref ulong dest_length, [CCode (array_length_type = "gulong")] uchar[] source);
                public static ulong adler32 (ulong crc = 0, [CCode (array_length_type = "guint")] uint8[]? buf = null);
                public static ulong crc32 (ulong crc = 0, [CCode (array_length_type = "guint")] uint8[]? buf = null);
        }