]> wimlib.net Git - wimlib/blobdiff - examples/decompressfile.c
win32_apply.c: WRITE_DAC is no longer needed when creating directory
[wimlib] / examples / decompressfile.c
index 8e461d43f86d33110c1171a8325b3d1ca96012c8..cc2b758e5d49644fda3b21f00fff73125993c0dd 100644 (file)
@@ -1,8 +1,26 @@
 /*
- * decompressfile.c
+ * decompressfile.c - decompression API example
  *
- * An example of using wimlib's compression API to decompress a file compressed
- * with the compressfile.c program.
+ * The following copying information applies to this specific source code file:
+ *
+ * Written in 2014 by Eric Biggers <ebiggers3@gmail.com>
+ *
+ * To the extent possible under law, the author(s) have dedicated all copyright
+ * and related and neighboring rights to this software to the public domain
+ * worldwide via the Creative Commons Zero 1.0 Universal Public Domain
+ * Dedication (the "CC0").
+ *
+ * This software is distributed in the hope that it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
+ * FOR A PARTICULAR PURPOSE. See the CC0 for more details.
+ *
+ * You should have received a copy of the CC0 along with this software; if not
+ * see <http://creativecommons.org/publicdomain/zero/1.0/>.
+ */
+
+/*
+ * This an example of using wimlib's compression API to decompress a file
+ * compressed with the compressfile.c program.
  *
  * This program does *not* have anything to do with WIM files other than the
  * fact that this makes use of compression formats that are used in WIM files.
@@ -24,9 +42,6 @@
  *
  * The compressed file format created here is simply a series of compressed
  * chunks.  A real format would need to have checksums and other metadata.
- *
- * The author dedicates this file to the public domain.
- * You can do whatever you want with this file.
  */
 
 #define _GNU_SOURCE
@@ -136,7 +151,7 @@ int main(int argc, char **argv)
 
        /* Create a decompressor for the compression type and chunk size with
         * the default parameters.  */
-       ret = wimlib_create_decompressor(ctype, chunk_size, NULL, &decompressor);
+       ret = wimlib_create_decompressor(ctype, chunk_size, &decompressor);
        if (ret != 0)
                error(1, 0, "Failed to create decompressor: %s",
                      wimlib_get_error_string(ret));