From: Anthony F. Molinaro Date: Thu, 22 Mar 2012 07:02:15 +0000 (+0000) Subject: THRIFT-1344 - fix http deprecation warning X-Git-Tag: 0.9.1~423 X-Git-Url: https://source.supwisdom.com/gerrit/gitweb?a=commitdiff_plain;h=e2378f69efa8c795470bf4ff2f96c85dd7642800;p=common%2Fthrift.git THRIFT-1344 - fix http deprecation warning git-svn-id: https://svn.apache.org/repos/asf/thrift/trunk@1303671 13f79535-47bb-0310-9956-ffa450edef68 --- diff --git a/lib/erl/src/thrift_http_transport.erl b/lib/erl/src/thrift_http_transport.erl index 7d0226f3..46bcede5 100644 --- a/lib/erl/src/thrift_http_transport.erl +++ b/lib/erl/src/thrift_http_transport.erl @@ -87,7 +87,7 @@ flush(State = #http_transport{host = Host, {State, ok}; WBinary -> {ok, {{_Version, 200, _ReasonPhrase}, _Headers, Body}} = - http:request(post, + httpc:request(post, {"http://" ++ Host ++ Path, [{"User-Agent", "Erlang/thrift_http_transport"} | ExtraHeaders], "application/x-thrift", @@ -114,6 +114,3 @@ read(State = #http_transport{read_buffer = RBuf}, Len) when is_integer(Len) -> _ -> {State, {error, 'EOF'}} end. - -min(A,B) when A A; -min(_,B) -> B.