Skip to content
Commit bae0c643 authored by Milan Crha's avatar Milan Crha
Browse files

Make camel_stream_write() try to write all bytes at once

The default implementation of CamelStream::write() used
g_output_stream_write() method, which could write only a partial
content, returning how many bytes had been actually written. That's
fine, but not each caller counted with this, thus for example
a CamelStreamFilter::write() failed when only partial buffer had
been written, which could cause a silent failure on message send.
Easier than taking care of the not-whole-buffer-written state
at each place of the usage is to use g_output_stream_write_all()
function instead, which fails only on errors.

This had been reported downstream as:
https://bugzilla.redhat.com/show_bug.cgi?id=1186815
parent 60c13606
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment