Projects
home:sicherha:branches:Kolab:16
erlang-eimap
Log In
Username
Password
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
Expand all
Collapse all
Difference Between Revision 6 and
Kolab:16
/
erlang-eimap
View file
use_iolist_to_binary.patch
Added
@@ -0,0 +1,22 @@ +Instead of converting the values from zlib:deflate to binary by hand we can use +the iolist_to_binary() function from erlang; this allows us to convert +also nested iolists. +diff -rupN eimap-0.4.0.ori/src/eimap.erl eimap-0.4.0/src/eimap.erl +--- eimap-0.4.0.ori/src/eimap.erl 2016-11-11 15:49:11.000000000 +0100 ++++ eimap-0.4.0/src/eimap.erl 2020-03-21 20:36:12.850230642 +0100 +@@ -478,13 +478,10 @@ reenque_command(Command, State) -> + State#state { command_queue = queue:in_r(Command, State#state.command_queue) }. + + inflated(Data, #state{ inflator = undefined }) -> Data; +-inflated(Data, #state{ inflator = Inflator }) -> joined(zlib:inflate(Inflator, Data), <<>>). ++inflated(Data, #state{ inflator = Inflator }) -> iolist_to_binary(zlib:inflate(Inflator, Data)). + + deflated(Data, #state{ deflator = undefined }) -> Data; +-deflated(Data, #state{ deflator = Deflator }) -> joined(zlib:deflate(Deflator, Data, sync), <<>>). +- +-joined([], Binary) -> Binary; +-joined([H|Rest], Binary) -> joined(Rest, <<Binary/binary, H/binary>>). ++deflated(Data, #state{ deflator = Deflator }) -> iolist_to_binary(zlib:deflate(Deflator, Data, sync)). + + reset_timeout(#state{ command_timeout = Timeout } = State) -> + cancel_timeout(State),
Locations
Projects
Search
Status Monitor
Help
Open Build Service
OBS Manuals
API Documentation
OBS Portal
Reporting a Bug
Contact
Mailing List
Forums
Chat (IRC)
Twitter
Open Build Service (OBS)
is an
openSUSE project
.