]> wimlib.net Git - wimlib/blobdiff - src/compress.c
Update hyperlinks
[wimlib] / src / compress.c
index 1b0d2c9f9aff5d0f04b1537bda5f264b3c9efd89..8396316dca06493a35560977c6259501dc0fbfa5 100644 (file)
@@ -19,7 +19,7 @@
  * details.
  *
  * You should have received a copy of the GNU Lesser General Public License
- * along with this file; if not, see http://www.gnu.org/licenses/.
+ * along with this file; if not, see https://www.gnu.org/licenses/.
  */
 
 #ifdef HAVE_CONFIG_H
@@ -122,6 +122,11 @@ wimlib_create_compressor(enum wimlib_compression_type ctype,
 {
        bool destructive;
        struct wimlib_compressor *c;
+       int ret;
+
+       ret = wimlib_global_init(0);
+       if (ret)
+               return ret;
 
        destructive = (compression_level & WIMLIB_COMPRESSOR_FLAG_DESTRUCTIVE);
        compression_level &= ~WIMLIB_COMPRESSOR_FLAG_DESTRUCTIVE;
@@ -146,8 +151,6 @@ wimlib_create_compressor(enum wimlib_compression_type ctype,
        c->ctype = ctype;
        c->max_block_size = max_block_size;
        if (c->ops->create_compressor) {
-               int ret;
-
                if (compression_level == 0)
                        compression_level = default_compression_levels[ctype];
                if (compression_level == 0)