diff --git a/sca-cpp/trunk/modules/http/httpd.hpp b/sca-cpp/trunk/modules/http/httpd.hpp index 768537aa03..d9570ce5bd 100644 --- a/sca-cpp/trunk/modules/http/httpd.hpp +++ b/sca-cpp/trunk/modules/http/httpd.hpp @@ -344,7 +344,7 @@ const failable writeResult(const failable >& ls, const string& return OK; } ap_set_content_type(r, apr_pstrdup(r->pool, c_str(ct))); - ap_rputs(c_str(ob), r); + ap_rwrite(c_str(ob), (int)length(ob), r); return OK; } diff --git a/sca-cpp/trunk/modules/server/mod-eval.hpp b/sca-cpp/trunk/modules/server/mod-eval.hpp index efca2058e5..27657dd587 100644 --- a/sca-cpp/trunk/modules/server/mod-eval.hpp +++ b/sca-cpp/trunk/modules/server/mod-eval.hpp @@ -140,7 +140,7 @@ const failable get(request_rec* r, const lambda&)>& } // Write an empty list as a JSON empty value - if (isNil(c)) { + if (isNil((list)c)) { js::JSContext cx; return httpd::writeResult(json::writeJSON(list(), cx), "application/json", r); }