summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFilipe David Borba Manana <fdmanana@apache.org>2011-03-05 17:54:22 +0000
committerFilipe David Borba Manana <fdmanana@apache.org>2011-03-05 17:54:22 +0000
commit68b52ba14777198ad3bfd2bcca1760ade2fc5290 (patch)
tree9c029b36a195743cde7b2c5a9c4c8e54315a707b
parent834c5c9c6f98db08a80b7ca1bac9d133e718793e (diff)
Merged revision 1076368 from trunk
Catch all in couch_util:to_binary/1 list argument clause When a list_to_binary call fails, the error tag is 'error' and not 'throw'. This was noticed when this clause was being hit in an error clause of the replication http handler (couch_httpd_replicator.erl). git-svn-id: https://svn.apache.org/repos/asf/couchdb/branches/1.1.x@1078317 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--src/couchdb/couch_util.erl2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/couchdb/couch_util.erl b/src/couchdb/couch_util.erl
index 3de7739b..53dfe5e3 100644
--- a/src/couchdb/couch_util.erl
+++ b/src/couchdb/couch_util.erl
@@ -340,7 +340,7 @@ to_binary(V) when is_list(V) ->
try
list_to_binary(V)
catch
- _ ->
+ _:_ ->
list_to_binary(io_lib:format("~p", [V]))
end;
to_binary(V) when is_atom(V) ->