Skip to content
This repository has been archived by the owner on Oct 22, 2021. It is now read-only.

Commit

Permalink
Tagging 1.0.2
Browse files Browse the repository at this point in the history
git-svn-id: https://svn.apache.org/repos/asf/couchdb/tags/1.0.2@1057433 13f79535-47bb-0310-9956-ffa450edef68
  • Loading branch information
davisp committed Jan 11, 2011
2 parents 79bea41 + 6ce291d commit 89d5db8
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 9 deletions.
4 changes: 4 additions & 0 deletions share/www/database.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,10 @@
$("h1 strong").text(page.db.name);
var viewPath = page.viewName || "_all_docs";
if (viewPath != "_temp_view" && viewPath != "_design_docs") {
viewPath = $.map(viewPath.split("/"), function (part) {
return encodeURIComponent(part);
}).join("/");

$("h1 a.raw").attr("href", "/" + encodeURIComponent(page.db.name) +
"/" + viewPath);
}
Expand Down
2 changes: 1 addition & 1 deletion share/www/script/couch_test_runner.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ function loadScript(url) {
if((url.substr(0, 7) == "http://")
|| (url.substr(0, 2) == "//")
|| (url.substr(0, 5) == "data:")
|| (url.substr(0, 11) == "javsacript:")) {
|| (url.substr(0, 11) == "javascript:")) {
throw "Not loading remote test scripts";
}
if (typeof document != "undefined") document.write('<script src="'+url+'"></script>');
Expand Down
8 changes: 4 additions & 4 deletions share/www/script/futon.browse.js
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@

var viewName = (urlParts.length > 0) ? urlParts.join("/") : null;
if (viewName) {
$.futon.storage.set("view", viewName);
$.futon.storage.set("view", decodeURIComponent(viewName));
} else {
viewName = $.futon.storage.get("view");
if (viewName) {
Expand All @@ -128,6 +128,7 @@
var db = $.couch.db(dbName);

this.dbName = dbName;
viewName = decodeURIComponent(viewName);
this.viewName = viewName;
this.viewLanguage = "javascript";
this.db = db;
Expand Down Expand Up @@ -578,7 +579,7 @@

this.updateDesignDocLink = function() {
if (viewName && /^_design/.test(viewName)) {
var docId = "_design/" + decodeURIComponent(viewName.split("/")[1]);
var docId = "_design/" + encodeURIComponent(decodeURIComponent(viewName).split("/")[1]);
$("#designdoc-link").attr("href", "document.html?" +
encodeURIComponent(dbName) + "/" + $.couch.encodeDocId(docId)).text(docId);
} else {
Expand Down Expand Up @@ -774,8 +775,7 @@
if (page.isDirty) {
db.query(currentMapCode, currentReduceCode, page.viewLanguage, options);
} else {
var viewParts = viewName.split('/');

var viewParts = decodeURIComponent(viewName).split('/');
if ($.futon.storage.get("stale")) {
options.stale = "ok";
}
Expand Down
13 changes: 9 additions & 4 deletions src/ibrowse/ibrowse_http_client.erl
Original file line number Diff line number Diff line change
Expand Up @@ -287,10 +287,14 @@ handle_sock_data(Data, #state{status = get_header}=State) ->
{error, _Reason} ->
shutting_down(State),
{stop, normal, State};
State_1 ->
active_once(State_1),
State_2 = set_inac_timer(State_1),
{noreply, State_2}
#state{socket = Socket, status = Status, cur_req = CurReq} = State_1 ->
case {Status, CurReq} of
{get_header, #request{caller_controls_socket = true}} ->
do_setopts(Socket, [{active, once}], State_1);
_ ->
active_once(State_1)
end,
{noreply, set_inac_timer(State_1)}
end;

handle_sock_data(Data, #state{status = get_body,
Expand Down Expand Up @@ -683,6 +687,7 @@ send_req_1(From,
Headers, Method, Body, Options, Timeout,
#state{status = Status,
socket = Socket} = State) ->
cancel_timer(State#state.inactivity_timer_ref, {eat_message, timeout}),
ReqId = make_req_id(),
Resp_format = get_value(response_format, Options, list),
Caller_socket_options = get_value(socket_options, Options, []),
Expand Down

0 comments on commit 89d5db8

Please sign in to comment.