<feed xmlns='http://www.w3.org/2005/Atom'>
<title>guix.git/guix/zlib.scm, branch master</title>
<subtitle>Personal branch of https://git.savannah.gnu.org/cgit/guix.git/ for implementing 'guix deploy'.
</subtitle>
<id>https://www.git.jakob.space/guix.git/atom?h=master</id>
<link rel='self' href='https://www.git.jakob.space/guix.git/atom?h=master'/>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/'/>
<updated>2017-11-19T22:09:01Z</updated>
<entry>
<title>zlib: Fix race condition when closing gzip ports.</title>
<updated>2017-11-19T22:09:01Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2017-11-19T22:02:29Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=85f4f7b79040d982c6a655c898b4cd00d868fa9c'/>
<id>urn:sha1:85f4f7b79040d982c6a655c898b4cd00d868fa9c</id>
<content type='text'>
Fixes &lt;https://bugs.gnu.org/29335&gt;.

* guix/zlib.scm (close-procedure): Remove.
(make-gzip-input-port): Do (dup (fileno port)) to get a file descriptor
for 'gzdopen'.  Close PORT before returning.  Use 'gzclose' as the
'close' procedure of the returned port.
(make-gzip-output-port): Likewise.
</content>
</entry>
<entry>
<title>zlib: Fix memory leak due to revealed ports not being GC'd.</title>
<updated>2017-10-11T13:20:50Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2017-10-11T13:14:16Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=85a2b58987bc32e33e63bea86c1a94496b796ae9'/>
<id>urn:sha1:85a2b58987bc32e33e63bea86c1a94496b796ae9</id>
<content type='text'>
Fixes &lt;https://bugs.gnu.org/28784&gt;.

This mostly reverts 81a0f1cdf12e7bcc34c1203f034a323fa8f52cf5, which
introduced a regression: revealed ports are *never* GC'd (contrary to
what Guile's manual suggests).

In addition to the revert, 'close-procedure' now explicitly swallows
EBADF errors when 'close-port' is called.

* guix/zlib.scm (close-procedure): New procedure.
(make-gzip-input-port)[gzfile]: Use 'fileno' instead of 'port-&gt;fdes'.
Use 'close-procedure' instead of 'gzclose'.
(make-gzip-output-port): Likewise.
* tests/zlib.scm ("compression/decompression pipe"): Use 'port-closed?'
to determine whether PARENT has been closed.
</content>
</entry>
<entry>
<title>zlib: Don't rely on EBADF being ignored by 'fport_close'.</title>
<updated>2017-03-15T14:19:53Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2017-03-15T09:40:51Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=81a0f1cdf12e7bcc34c1203f034a323fa8f52cf5'/>
<id>urn:sha1:81a0f1cdf12e7bcc34c1203f034a323fa8f52cf5</id>
<content type='text'>
In 2.2, 'fport_close' no longer swallows EBADF and instead raises a
'system-error' for this.  This commit adjusts for 2.2.

* guix/zlib.scm (close-procedure): Remove.
(make-gzip-input-port): Use 'port-&gt;fdes' instead of 'fileno'.
Use 'gzclose' instead of 'close-procedure'.
(make-gzip-output-port): Likewise.
* tests/zlib.scm ("compression/decompression pipe"): Don't check whether
PARENT is closed using 'port-closed?'.  Instead, use 'seek' on the
underlying FD and check for EBADF.
</content>
</entry>
<entry>
<title>zlib: Protect against non-empty port internal buffers.</title>
<updated>2016-07-27T10:45:01Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2016-07-27T10:39:27Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=688ec13c459602d475bccd3638a6802dc0a6ce23'/>
<id>urn:sha1:688ec13c459602d475bccd3638a6802dc0a6ce23</id>
<content type='text'>
* guix/zlib.scm (make-gzip-input-port)[gzfile]: Error out
if (drain-input port) returns a non-empty string.
* guix/zlib.scm (make-gzip-output-port)[gzfile]: Call 'force-output'.
</content>
</entry>
<entry>
<title>zlib: Clarify when 'gzread!' can return zero.</title>
<updated>2016-07-27T10:45:01Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2016-07-27T09:44:34Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=d00240c36e7bcf73f63e9e21c6ecec6f86d354ab'/>
<id>urn:sha1:d00240c36e7bcf73f63e9e21c6ecec6f86d354ab</id>
<content type='text'>
* guix/zlib.scm (gzread!): Augment docstring to clarify when zero is
returned (based on reading zlib code).
(make-gzip-input-port)[read!]: Remove scary comment.
</content>
</entry>
<entry>
<title>Add (guix zlib).</title>
<updated>2016-07-18T22:07:12Z</updated>
<author>
<name>Ludovic Courtès</name>
<email>ludo@gnu.org</email>
</author>
<published>2016-07-18T21:14:14Z</published>
<link rel='alternate' type='text/html' href='https://www.git.jakob.space/guix.git/commit/?id=721539026dda02e58addbb618f2102b31a2927f8'/>
<id>urn:sha1:721539026dda02e58addbb618f2102b31a2927f8</id>
<content type='text'>
* guix/zlib.scm, tests/zlib.scm: New files.
* Makefile.am (MODULES): Add guix/zlib.scm.
(SCM_TESTS): Add tests/zlib.scm.
* m4/guix.m4 (GUIX_LIBGCRYPT_LIBDIR): New macro.
* configure.ac (LIBGCRYPT_LIBDIR): Use it.  Define and substitute
'LIBZ'.
* guix/config.scm.in (%libz): New variable.
</content>
</entry>
</feed>
