<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hi erverybody!</p>
<p>I'm testing a cairo backend I wrote for the GNU Lilypond music
engraver.<br>
</p>
<p>I generate several output formats in parallel and test for errors
using this C++ code:</p>
<blockquote><font face="monospace"> for (auto &cr :
Cairo_output.contexts) // loop over a set of crs<br>
{<br>
auto status = cairo_status (cr);<br>
if (status != CAIRO_STATUS_SUCCESS)<br>
error (_f ("Cairo status %s", cairo_status_to_string
(status))); // display an error msg and abort<br>
}</font></blockquote>
<p>If writing to an output file fails because there is no more free
disk space and the cr is connected to a pdf surface this works
fine:</p>
<blockquote><font face="monospace">Fitting music on 1 or 2 pages...<br>
Drawing systems...<br>
Generating test.cairo.pdf ...<br>
fatal error: Cairo status reports 'error while writing to output
stream'</font></blockquote>
<p>Unfortunately this code fails for the cairo postscript backend
and the cairo svg backend - <font face="monospace">cairo_status</font>
reports <font face="monospace">CAIRO_STATUS_SUCCESS</font> even
if writing to disk failed because there is no free disk space.<br>
</p>
<p>Tested versions: 1.16.0, git master</p>
<p>Knut<br>
</p>
</body>
</html>