Document zip_register_cancel_callback_with_state.

Closes #238.
diff --git a/man/CMakeLists.txt b/man/CMakeLists.txt
index 37b84a0..65c78549 100644
--- a/man/CMakeLists.txt
+++ b/man/CMakeLists.txt
@@ -54,6 +54,7 @@
   zip_libzip_version.3
   zip_name_locate.3
   zip_open.3
+  zip_register_cancel_callback_with_state.3
   zip_register_progress_callback.3
   zip_register_progress_callback_with_state.3
   zip_rename.3
diff --git a/man/libzip.html b/man/libzip.html
index bda1461..ecca031 100644
--- a/man/libzip.html
+++ b/man/libzip.html
@@ -226,6 +226,7 @@
 <ul class="Bl-bullet Bl-compact">
   <li><a class="Xr" href="zip_file_attributes_init.html">zip_file_attributes_init(3)</a></li>
   <li><a class="Xr" href="zip_libzip_version.html">zip_libzip_version(3)</a></li>
+  <li><a class="Xr" href="zip_register_cancel_callback_with_state.html">zip_register_cancel_callback_with_state(3)</a></li>
   <li><a class="Xr" href="zip_register_progress_callback_with_state.html">zip_register_progress_callback_with_state(3)</a></li>
   <li><a class="Xr" href="zip_set_archive_comment.html">zip_set_archive_comment(3)</a></li>
   <li><a class="Xr" href="zip_set_archive_flag.html">zip_set_archive_flag(3)</a></li>
@@ -257,7 +258,7 @@
 </div>
 <table class="foot">
   <tr>
-    <td class="foot-date">September 15, 2020</td>
+    <td class="foot-date">April 6, 2021</td>
     <td class="foot-os">NiH</td>
   </tr>
 </table>
diff --git a/man/libzip.man b/man/libzip.man
index aa12a9d..7f5361f 100644
--- a/man/libzip.man
+++ b/man/libzip.man
@@ -30,7 +30,7 @@
 .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
 .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 .\"
-.TH "LIBZIP" "3" "September 15, 2020" "NiH" "Library Functions Manual"
+.TH "LIBZIP" "3" "April 6, 2021" "NiH" "Library Functions Manual"
 .nh
 .if n .ad l
 .SH "NAME"
@@ -275,6 +275,9 @@
 zip_libzip_version(3)
 .TP 4n
 \fB\(bu\fR
+zip_register_cancel_callback_with_state(3)
+.TP 4n
+\fB\(bu\fR
 zip_register_progress_callback_with_state(3)
 .TP 4n
 \fB\(bu\fR
diff --git a/man/libzip.mdoc b/man/libzip.mdoc
index b3ade6b..fd06039 100644
--- a/man/libzip.mdoc
+++ b/man/libzip.mdoc
@@ -29,7 +29,7 @@
 .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
 .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd September 15, 2020
+.Dd April 6, 2021
 .Dt LIBZIP 3
 .Os
 .Sh NAME
@@ -226,6 +226,8 @@
 .It
 .Xr zip_libzip_version 3
 .It
+.Xr zip_register_cancel_callback_with_state 3
+.It
 .Xr zip_register_progress_callback_with_state 3
 .It
 .Xr zip_set_archive_comment 3
diff --git a/man/zip_close.html b/man/zip_close.html
index d8c1858..1de133c 100644
--- a/man/zip_close.html
+++ b/man/zip_close.html
@@ -72,6 +72,11 @@
   <var class="Ar">archive</var> is left unchanged and must still be freed.
 <p class="Pp">To close and free a zip archive without saving changes, use
     <a class="Xr" href="zip_discard.html">zip_discard(3)</a>.</p>
+<p class="Pp">Progress updates for GUIs can be implemented using
+    <a class="Xr" href="zip_register_progress_callback_with_state.html">zip_register_progress_callback_with_state(3)</a>.
+    Cancelling the write of an archive during <code class="Nm">zip_close</code>
+    can be implemented using
+    <a class="Xr" href="zip_register_cancel_callback_with_state.html">zip_register_cancel_callback_with_state(3)</a>.</p>
 </section>
 <section class="Sh">
 <h1 class="Sh" id="RETURN_VALUES"><a class="permalink" href="#RETURN_VALUES">RETURN
@@ -120,6 +125,7 @@
   <a class="Xr" href="zip_fdopen.html">zip_fdopen(3)</a>,
   <a class="Xr" href="zip_get_error.html">zip_get_error(3)</a>,
   <a class="Xr" href="zip_open.html">zip_open(3)</a>,
+  <a class="Xr" href="zip_register_cancel_callback_with_state.html">zip_register_cancel_callback_with_state(3)</a>,
   <a class="Xr" href="zip_register_progress_callback_with_state.html">zip_register_progress_callback_with_state(3)</a>,
   <a class="Xr" href="zip_strerror.html">zip_strerror(3)</a>
 </section>
@@ -137,7 +143,7 @@
 </div>
 <table class="foot">
   <tr>
-    <td class="foot-date">September 17, 2019</td>
+    <td class="foot-date">April 6, 2021</td>
     <td class="foot-os">NiH</td>
   </tr>
 </table>
diff --git a/man/zip_close.man b/man/zip_close.man
index a5264eb..5dae788 100644
--- a/man/zip_close.man
+++ b/man/zip_close.man
@@ -30,7 +30,7 @@
 .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
 .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 .\"
-.TH "ZIP_CLOSE" "3" "September 17, 2019" "NiH" "Library Functions Manual"
+.TH "ZIP_CLOSE" "3" "April 6, 2021" "NiH" "Library Functions Manual"
 .nh
 .if n .ad l
 .SH "NAME"
@@ -66,6 +66,13 @@
 .PP
 To close and free a zip archive without saving changes, use
 zip_discard(3).
+.PP
+Progress updates for GUIs can be implemented using
+zip_register_progress_callback_with_state(3).
+Cancelling the write of an archive during
+\fBzip_close\fR
+can be implemented using
+zip_register_cancel_callback_with_state(3).
 .SH "RETURN VALUES"
 Upon successful completion 0 is returned.
 Otherwise, \-1 is returned and the error code in
@@ -123,6 +130,7 @@
 zip_fdopen(3),
 zip_get_error(3),
 zip_open(3),
+zip_register_cancel_callback_with_state(3),
 zip_register_progress_callback_with_state(3),
 zip_strerror(3)
 .SH "HISTORY"
diff --git a/man/zip_close.mdoc b/man/zip_close.mdoc
index b5bfd21..0b702a7 100644
--- a/man/zip_close.mdoc
+++ b/man/zip_close.mdoc
@@ -29,7 +29,7 @@
 .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
 .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 .\"
-.Dd September 17, 2019
+.Dd April 6, 2021
 .Dt ZIP_CLOSE 3
 .Os
 .Sh NAME
@@ -60,6 +60,13 @@
 .Pp
 To close and free a zip archive without saving changes, use
 .Xr zip_discard 3 .
+.Pp
+Progress updates for GUIs can be implemented using
+.Xr zip_register_progress_callback_with_state 3 .
+Cancelling the write of an archive during
+.Nm
+can be implemented using
+.Xr zip_register_cancel_callback_with_state 3 .
 .Sh RETURN VALUES
 Upon successful completion 0 is returned.
 Otherwise, \-1 is returned and the error code in
@@ -105,6 +112,7 @@
 .Xr zip_fdopen 3 ,
 .Xr zip_get_error 3 ,
 .Xr zip_open 3 ,
+.Xr zip_register_cancel_callback_with_state 3 ,
 .Xr zip_register_progress_callback_with_state 3 ,
 .Xr zip_strerror 3
 .Sh HISTORY
diff --git a/man/zip_register_cancel_callback_with_state.html b/man/zip_register_cancel_callback_with_state.html
new file mode 100644
index 0000000..5872b43
--- /dev/null
+++ b/man/zip_register_cancel_callback_with_state.html
@@ -0,0 +1,121 @@
+<!DOCTYPE html>
+<html>
+<!-- This is an automatically generated file.  Do not edit.
+   zip_register_cancel_callback_with_state.mdoc -- allow cancelling during zip_close
+   Copyright (C) 2021 Dieter Baron and Thomas Klausner
+  
+   This file is part of libzip, a library to manipulate ZIP archives.
+   The authors can be contacted at <libzip@nih.at>
+  
+   Redistribution and use in source and binary forms, with or without
+   modification, are permitted provided that the following conditions
+   are met:
+   1. Redistributions of source code must retain the above copyright
+      notice, this list of conditions and the following disclaimer.
+   2. Redistributions in binary form must reproduce the above copyright
+      notice, this list of conditions and the following disclaimer in
+      the documentation and/or other materials provided with the
+      distribution.
+   3. The names of the authors may not be used to endorse or promote
+      products derived from this software without specific prior
+      written permission.
+  
+   THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS
+   OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+   WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+   ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY
+   DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+   DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
+   GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+   INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+   IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+   OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+   IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+   -->
+<head>
+  <meta charset="utf-8"/>
+  <link rel="stylesheet" href="../nih-man.css" type="text/css" media="all"/>
+  <title>ZIP_REGISTER_CANCEL_CALLBACK_WITH_STATE(3)</title>
+</head>
+<body>
+<table class="head">
+  <tr>
+    <td class="head-ltitle">ZIP_REGISTER_CANCEL_CALLBACK_WITH_STATE(3)</td>
+    <td class="head-vol">Library Functions Manual</td>
+    <td class="head-rtitle">ZIP_REGISTER_CANCEL_CALLBACK_WITH_STATE(3)</td>
+  </tr>
+</table>
+<div class="manual-text">
+<section class="Sh">
+<h1 class="Sh" id="NAME"><a class="permalink" href="#NAME">NAME</a></h1>
+<code class="Nm">zip_register_cancel_callback_with_state</code> &#x2014;
+<div class="Nd">allow cancelling during zip_close</div>
+</section>
+<section class="Sh">
+<h1 class="Sh" id="LIBRARY"><a class="permalink" href="#LIBRARY">LIBRARY</a></h1>
+libzip (-lzip)
+</section>
+<section class="Sh">
+<h1 class="Sh" id="SYNOPSIS"><a class="permalink" href="#SYNOPSIS">SYNOPSIS</a></h1>
+<code class="In">#include &lt;<a class="In">zip.h</a>&gt;</code>
+<p class="Pp"><var class="Vt">typedef void (*zip_cancel_callback)(zip_t *,
+    double, void *);</var></p>
+<p class="Pp"><var class="Ft">void</var>
+  <br/>
+  <code class="Fn">zip_register_cancel_callback_with_state</code>(<var class="Fa" style="white-space: nowrap;">zip_t
+    *archive</var>,
+    <var class="Fa" style="white-space: nowrap;">zip_cancel_callback
+    callback</var>, <var class="Fa" style="white-space: nowrap;">void
+    (*ud_free)(void *)</var>, <var class="Fa" style="white-space: nowrap;">void
+    *ud</var>);</p>
+</section>
+<section class="Sh">
+<h1 class="Sh" id="DESCRIPTION"><a class="permalink" href="#DESCRIPTION">DESCRIPTION</a></h1>
+This function can be used to cancel writing of a zip archive during
+  <a class="Xr" href="zip_close.html">zip_close(3)</a>.
+<p class="Pp">The
+    <code class="Fn">zip_register_cancel_callback_with_state</code>() function
+    registers a callback function <var class="Ar">callback</var> for the zip
+    archive <var class="Ar">archive</var>. The <var class="Ar">ud_free</var>
+    function is called during cleanup for deleting the userdata supplied in
+    <var class="Ar">ud</var>.</p>
+<p class="Pp">The callback function is called during
+    <a class="Xr" href="zip_close.html">zip_close(3)</a> in regular intervals
+    (after every zip archive entry that's completely written to disk, and while
+    writing data for entries) with zip archive <var class="Ar">archive</var>,
+    the current progress state (see
+    <a class="Xr" href="zip_register_progress_callback_with_state.html">zip_register_progress_callback_with_state(3)</a>)
+    as a <var class="Vt">double</var>, and the user-provided user-data
+    <var class="Ar">ud</var> as arguments. The progress state is a
+    <var class="Vt">double</var> in the range from 0.0 to 1.0.</p>
+<p class="Pp">The callback function should be fast, since it will be called
+    often.</p>
+</section>
+<section class="Sh">
+<h1 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE
+  ALSO</a></h1>
+<a class="Xr" href="libzip.html">libzip(3)</a>,
+  <a class="Xr" href="zip_close.html">zip_close(3)</a>,
+  <a class="Xr" href="zip_register_progress_callback_with_state.html">zip_register_progress_callback_with_state(3)</a>
+</section>
+<section class="Sh">
+<h1 class="Sh" id="HISTORY"><a class="permalink" href="#HISTORY">HISTORY</a></h1>
+<code class="Fn">zip_register_cancel_callback_with_state</code>() was added in
+  libzip 1.6.0.
+</section>
+<section class="Sh">
+<h1 class="Sh" id="AUTHORS"><a class="permalink" href="#AUTHORS">AUTHORS</a></h1>
+<span class="An">Dieter Baron</span>
+  &lt;<a class="Mt" href="mailto:dillo@nih.at">dillo@nih.at</a>&gt; and
+  <span class="An">Thomas Klausner</span>
+  &lt;<a class="Mt" href="mailto:tk@giga.or.at">tk@giga.or.at</a>&gt;
+</section>
+</div>
+<table class="foot">
+  <tr>
+    <td class="foot-date">April 6, 2021</td>
+    <td class="foot-os">NiH</td>
+  </tr>
+</table>
+</body>
+</html>
diff --git a/man/zip_register_cancel_callback_with_state.man b/man/zip_register_cancel_callback_with_state.man
new file mode 100644
index 0000000..7ddf69c
--- /dev/null
+++ b/man/zip_register_cancel_callback_with_state.man
@@ -0,0 +1,94 @@
+.\" Automatically generated from an mdoc input file.  Do not edit.
+.\" zip_register_cancel_callback_with_state.mdoc -- allow cancelling during zip_close
+.\" Copyright (C) 2021 Dieter Baron and Thomas Klausner
+.\"
+.\" This file is part of libzip, a library to manipulate ZIP archives.
+.\" The authors can be contacted at <libzip@nih.at>
+.\"
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:
+.\" 1. Redistributions of source code must retain the above copyright
+.\"    notice, this list of conditions and the following disclaimer.
+.\" 2. Redistributions in binary form must reproduce the above copyright
+.\"    notice, this list of conditions and the following disclaimer in
+.\"    the documentation and/or other materials provided with the
+.\"    distribution.
+.\" 3. The names of the authors may not be used to endorse or promote
+.\"    products derived from this software without specific prior
+.\"    written permission.
+.\"
+.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS
+.\" OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY
+.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
+.\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+.\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+.\"
+.TH "ZIP_REGISTER_CANCEL_CALLBACK_WITH_STATE" "3" "April 6, 2021" "NiH" "Library Functions Manual"
+.nh
+.if n .ad l
+.SH "NAME"
+\fBzip_register_cancel_callback_with_state\fR
+\- allow cancelling during zip_close
+.SH "LIBRARY"
+libzip (-lzip)
+.SH "SYNOPSIS"
+\fB#include <zip.h>\fR
+.sp
+\fItypedef void (*zip_cancel_callback)(zip_t *, double, void *);\fR
+.sp
+\fIvoid\fR
+.br
+.PD 0
+.HP 4n
+\fBzip_register_cancel_callback_with_state\fR(\fIzip_t\ *archive\fR, \fIzip_cancel_callback\ callback\fR, \fIvoid\ (*ud_free)(void\ *)\fR, \fIvoid\ *ud\fR);
+.PD
+.SH "DESCRIPTION"
+This function can be used to cancel writing of a zip archive during
+zip_close(3).
+.PP
+The
+\fBzip_register_cancel_callback_with_state\fR()
+function registers a callback function
+\fIcallback\fR
+for the zip archive
+\fIarchive\fR.
+The
+\fIud_free\fR
+function is called during cleanup for deleting the userdata supplied in
+\fIud\fR.
+.PP
+The callback function is called during
+zip_close(3)
+in regular intervals (after every zip archive entry that's completely
+written to disk, and while writing data for entries) with zip archive
+\fIarchive\fR,
+the current progress state (see
+zip_register_progress_callback_with_state(3))
+as a
+\fIdouble\fR,
+and the user-provided user-data
+\fIud\fR
+as arguments.
+The progress state is a
+\fIdouble\fR
+in the range from 0.0 to 1.0.
+.PP
+The callback function should be fast, since it will be called often.
+.SH "SEE ALSO"
+libzip(3),
+zip_close(3),
+zip_register_progress_callback_with_state(3)
+.SH "HISTORY"
+\fBzip_register_cancel_callback_with_state\fR()
+was added in libzip 1.6.0.
+.SH "AUTHORS"
+Dieter Baron <\fIdillo@nih.at\fR>
+and
+Thomas Klausner <\fItk@giga.or.at\fR>
diff --git a/man/zip_register_cancel_callback_with_state.mdoc b/man/zip_register_cancel_callback_with_state.mdoc
new file mode 100644
index 0000000..58fdc59
--- /dev/null
+++ b/man/zip_register_cancel_callback_with_state.mdoc
@@ -0,0 +1,88 @@
+.\" zip_register_cancel_callback_with_state.mdoc -- allow cancelling during zip_close
+.\" Copyright (C) 2021 Dieter Baron and Thomas Klausner
+.\"
+.\" This file is part of libzip, a library to manipulate ZIP archives.
+.\" The authors can be contacted at <libzip@nih.at>
+.\"
+.\" Redistribution and use in source and binary forms, with or without
+.\" modification, are permitted provided that the following conditions
+.\" are met:
+.\" 1. Redistributions of source code must retain the above copyright
+.\"    notice, this list of conditions and the following disclaimer.
+.\" 2. Redistributions in binary form must reproduce the above copyright
+.\"    notice, this list of conditions and the following disclaimer in
+.\"    the documentation and/or other materials provided with the
+.\"    distribution.
+.\" 3. The names of the authors may not be used to endorse or promote
+.\"    products derived from this software without specific prior
+.\"    written permission.
+.\"
+.\" THIS SOFTWARE IS PROVIDED BY THE AUTHORS ``AS IS'' AND ANY EXPRESS
+.\" OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+.\" WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
+.\" ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHORS BE LIABLE FOR ANY
+.\" DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
+.\" DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE
+.\" GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
+.\" INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER
+.\" IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+.\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
+.\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+.\"
+.Dd April 6, 2021
+.Dt ZIP_REGISTER_CANCEL_CALLBACK_WITH_STATE 3
+.Os
+.Sh NAME
+.Nm zip_register_cancel_callback_with_state
+.Nd allow cancelling during zip_close
+.Sh LIBRARY
+libzip (-lzip)
+.Sh SYNOPSIS
+.In zip.h
+.Vt typedef void (*zip_cancel_callback)(zip_t *, double, void *);
+.Ft void
+.Fn zip_register_cancel_callback_with_state "zip_t *archive" "zip_cancel_callback callback" "void (*ud_free)(void *)" "void *ud"
+.Sh DESCRIPTION
+This function can be used to cancel writing of a zip archive during
+.Xr zip_close 3 .
+.Pp
+The
+.Fn zip_register_cancel_callback_with_state
+function registers a callback function
+.Ar callback
+for the zip archive
+.Ar archive .
+The
+.Ar ud_free
+function is called during cleanup for deleting the userdata supplied in
+.Ar ud .
+.Pp
+The callback function is called during
+.Xr zip_close 3
+in regular intervals (after every zip archive entry that's completely
+written to disk, and while writing data for entries) with zip archive
+.Ar archive ,
+the current progress state (see
+.Xr zip_register_progress_callback_with_state 3 )
+as a
+.Vt double ,
+and the user-provided user-data
+.Ar ud
+as arguments.
+The progress state is a
+.Vt double
+in the range from 0.0 to 1.0.
+.Pp
+The callback function should be fast, since it will be called often.
+.Sh SEE ALSO
+.Xr libzip 3 ,
+.Xr zip_close 3 ,
+.Xr zip_register_progress_callback_with_state 3
+.Sh HISTORY
+.Fn zip_register_cancel_callback_with_state
+was added in libzip 1.6.0.
+.Sh AUTHORS
+.An -nosplit
+.An Dieter Baron Aq Mt dillo@nih.at
+and
+.An Thomas Klausner Aq Mt tk@giga.or.at
diff --git a/man/zip_register_progress_callback_with_state.html b/man/zip_register_progress_callback_with_state.html
index 4faf331..a3cb554 100644
--- a/man/zip_register_progress_callback_with_state.html
+++ b/man/zip_register_progress_callback_with_state.html
@@ -93,7 +93,8 @@
 <h1 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE
   ALSO</a></h1>
 <a class="Xr" href="libzip.html">libzip(3)</a>,
-  <a class="Xr" href="zip_close.html">zip_close(3)</a>
+  <a class="Xr" href="zip_close.html">zip_close(3)</a>,
+  <a class="Xr" href="zip_register_cancel_callback_with_state.html">zip_register_cancel_callback_with_state(3)</a>
 </section>
 <section class="Sh">
 <h1 class="Sh" id="HISTORY"><a class="permalink" href="#HISTORY">HISTORY</a></h1>
diff --git a/man/zip_register_progress_callback_with_state.man b/man/zip_register_progress_callback_with_state.man
index f24905b..e6f8544 100644
--- a/man/zip_register_progress_callback_with_state.man
+++ b/man/zip_register_progress_callback_with_state.man
@@ -82,7 +82,8 @@
 This can be used to provide progress indicators for user interfaces.
 .SH "SEE ALSO"
 libzip(3),
-zip_close(3)
+zip_close(3),
+zip_register_cancel_callback_with_state(3)
 .SH "HISTORY"
 \fBzip_register_progress_callback_with_state\fR()
 was added in libzip 1.3.0.
diff --git a/man/zip_register_progress_callback_with_state.mdoc b/man/zip_register_progress_callback_with_state.mdoc
index 7eea3d6..5726358 100644
--- a/man/zip_register_progress_callback_with_state.mdoc
+++ b/man/zip_register_progress_callback_with_state.mdoc
@@ -75,7 +75,8 @@
 This can be used to provide progress indicators for user interfaces.
 .Sh SEE ALSO
 .Xr libzip 3 ,
-.Xr zip_close 3
+.Xr zip_close 3 ,
+.Xr zip_register_cancel_callback_with_state 3
 .Sh HISTORY
 .Fn zip_register_progress_callback_with_state
 was added in libzip 1.3.0.
diff --git a/man/zip_set_file_compression.html b/man/zip_set_file_compression.html
index fbdb531..107cd36 100644
--- a/man/zip_set_file_compression.html
+++ b/man/zip_set_file_compression.html
@@ -88,14 +88,26 @@
   <dt><a class="permalink" href="#ZIP_CM_DEFLATE"><code class="Dv" id="ZIP_CM_DEFLATE">ZIP_CM_DEFLATE</code></a></dt>
   <dd>Deflate the file with the <a class="Xr" href="http://pubs.opengroup.org/onlinepubs/9699919799/functions/zlib.html">zlib(3)</a>
       algorithm and default options.</dd>
+  <dt><a class="permalink" href="#ZIP_CM_XZ"><code class="Dv" id="ZIP_CM_XZ">ZIP_CM_XZ</code></a></dt>
+  <dd>Use the <a class="Xr" href="http://pubs.opengroup.org/onlinepubs/9699919799/functions/xz.html">xz(1)</a> algorithm for
+    compression</dd>
+  <dt><a class="permalink" href="#ZIP_CM_ZSTD"><code class="Dv" id="ZIP_CM_ZSTD">ZIP_CM_ZSTD</code></a></dt>
+  <dd>Use the <a class="Xr" href="http://pubs.opengroup.org/onlinepubs/9699919799/functions/zstd.html">zstd(1)</a> algorithm for
+      compression</dd>
 </dl>
 <p class="Pp"><i class="Em">NOTE</i>: Only the deflate and store methods can be
     assumed to be universally supported.</p>
 <p class="Pp">The <var class="Ar">comp_flags</var> argument defines the
-    compression level, 1 being fastest compression and 9 highest. Allowed values
-    are 0 (which uses the default compression for the algorithm) and 1-9, other
-    values are undefined. Further compression method specific flags might be
-    added over time.</p>
+    compression level. This value is dependent on the compression algorithm. In
+    general, lower numbers mean faster de/compression and higher numbers mean
+    slower de/compression. For <code class="Dv">ZIP_CM_BZIP</code>,
+    <code class="Dv">ZIP_CM_DEFLATE</code>, and
+    <code class="Dv">ZIP_CM_XZ</code> 1 is the fastest compression and 9 the
+    best, 0 chooses the default. For <code class="Dv">ZIP_CM_ZSTD</code> the
+    value go from <a class="Xr" href="http://pubs.opengroup.org/onlinepubs/9699919799/functions/ZSTD_minCLevel.html">ZSTD_minCLevel(3)</a>
+    to <a class="Xr" href="http://pubs.opengroup.org/onlinepubs/9699919799/functions/ZSTD_maxCLevel.html">ZSTD_maxCLevel(3)</a>.</p>
+<p class="Pp">Further compression method specific flags might be added over
+    time.</p>
 <p class="Pp">The current compression method for a file in a zip archive can be
     determined using <a class="Xr" href="zip_stat.html">zip_stat(3)</a>.</p>
 </section>
@@ -141,7 +153,7 @@
 </div>
 <table class="foot">
   <tr>
-    <td class="foot-date">April 2, 2020</td>
+    <td class="foot-date">March 19, 2021</td>
     <td class="foot-os">NiH</td>
   </tr>
 </table>
diff --git a/man/zip_set_file_compression.man b/man/zip_set_file_compression.man
index 7f12f8d..45402d0 100644
--- a/man/zip_set_file_compression.man
+++ b/man/zip_set_file_compression.man
@@ -30,7 +30,7 @@
 .\" OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN
 .\" IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 .\"
-.TH "ZIP_SET_FILE_COMPRESSION" "3" "April 2, 2020" "NiH" "Library Functions Manual"
+.TH "ZIP_SET_FILE_COMPRESSION" "3" "March 19, 2021" "NiH" "Library Functions Manual"
 .nh
 .if n .ad l
 .SH "NAME"
@@ -83,6 +83,16 @@
 Deflate the file with the
 zlib(3)
 algorithm and default options.
+.TP 19n
+\fRZIP_CM_XZ\fR
+Use the
+xz(1)
+algorithm for compression
+.TP 19n
+\fRZIP_CM_ZSTD\fR
+Use the
+zstd(1)
+algorithm for compression
 .PP
 \fINOTE\fR:
 Only the deflate and store methods can be assumed to be universally
@@ -90,10 +100,23 @@
 .PP
 The
 \fIcomp_flags\fR
-argument defines the compression level, 1 being fastest compression
-and 9 highest.
-Allowed values are 0 (which uses the default compression for the
-algorithm) and 1-9, other values are undefined.
+argument defines the compression level.
+This value is dependent on the compression algorithm.
+In general, lower numbers mean faster de/compression and higher
+numbers mean slower de/compression.
+For
+\fRZIP_CM_BZIP\fR,
+\fRZIP_CM_DEFLATE\fR,
+and
+\fRZIP_CM_XZ\fR
+1 is the fastest compression and 9 the best, 0 chooses the default.
+For
+\fRZIP_CM_ZSTD\fR
+the value go from
+ZSTD_minCLevel(3)
+to
+ZSTD_maxCLevel(3).
+.PP
 Further compression method specific flags might be added over time.
 .PP
 The current compression method for a file in a zip archive can be