testing return of empty binary from 0-length thrrift read


git-svn-id: https://svn.apache.org/repos/asf/incubator/thrift/trunk@666455 13f79535-47bb-0310-9956-ffa450edef68
diff --git a/lib/alterl/src/thrift_binary_protocol.erl b/lib/alterl/src/thrift_binary_protocol.erl
index c1f9d4e..c84701e 100644
--- a/lib/alterl/src/thrift_binary_protocol.erl
+++ b/lib/alterl/src/thrift_binary_protocol.erl
@@ -269,5 +269,6 @@
     {ok, Sz}  = read(This, i32),
     {ok, Bin} = read(This, Sz);
 
+read(This, 0) -> {ok, <<>>};
 read(This, Len) when is_integer(Len), Len >= 0 ->
     thrift_transport:read(This#binary_protocol.transport, Len).