THRIFT-1343 - remove internal min function, it seems the same as erlang:min/2
authorAnthony F. Molinaro <molinaro@apache.org>
Thu, 22 Mar 2012 07:04:37 +0000 (07:04 +0000)
committerAnthony F. Molinaro <molinaro@apache.org>
Thu, 22 Mar 2012 07:04:37 +0000 (07:04 +0000)
git-svn-id: https://svn.apache.org/repos/asf/thrift/trunk@1303672 13f79535-47bb-0310-9956-ffa450edef68

lib/erl/src/thrift_framed_transport.erl
lib/erl/src/thrift_memory_buffer.erl

index 2c5531a..eca3cbe 100644 (file)
@@ -101,11 +101,3 @@ read(State0 = #framed_transport{wrapped = Wrapped0, read_buffer = RBuf},
         { State0#framed_transport{wrapped = Wrapped1, read_buffer=RBuf2},
           {ok, Data} }
     end.
-
-%%--------------------------------------------------------------------
-%% Internal functions
-%%--------------------------------------------------------------------
-
-min(A,B) when A<B -> A;
-min(_,B)          -> B.
-
index ce7c1da..53abbc4 100644 (file)
@@ -60,10 +60,3 @@ read(State = #memory_buffer{buffer = Buf}, Len) when is_integer(Len) ->
     Give = min(iolist_size(Binary), Len),
     {Result, Remaining} = split_binary(Binary, Give),
     {State#memory_buffer{buffer = Remaining}, {ok, Result}}.
-
-%%--------------------------------------------------------------------
-%% Internal functions
-%%--------------------------------------------------------------------
-min(A,B) when A<B -> A;
-min(_,B)          -> B.
-