From 219cd4db7e62878b3bd2cb537c73cb8acf04bf47 Mon Sep 17 00:00:00 2001 From: Adam Kocoloski Date: Wed, 23 Sep 2009 20:43:35 +0000 Subject: reject attempts to upload invalid UTF-8 JSON. Closes COUCHDB-345 This patch requires JSON to be encoded using UTF-8. In the future we will accept other encodings. Thanks Joan Touzet and James Dumay for the bug reports and Curt Arnold for patches and discussion. git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@818249 13f79535-47bb-0310-9956-ffa450edef68 --- share/www/script/test/view_errors.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'share') diff --git a/share/www/script/test/view_errors.js b/share/www/script/test/view_errors.js index 256e9569..0f90c46f 100644 --- a/share/www/script/test/view_errors.js +++ b/share/www/script/test/view_errors.js @@ -55,7 +55,7 @@ couchTests.view_errors = function(debug) { map : "function(doc){emit(doc.integer)}" }) }); - T(JSON.parse(xhr.responseText).error == "invalid_json"); + T(JSON.parse(xhr.responseText).error == "bad_request"); // views should ignore Content-Type, like the rest of CouchDB var xhr = CouchDB.request("POST", "/test_suite_db/_temp_view", { -- cgit v1.2.3