summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorWido den Hollander <wido@widodh.nl>2010-09-27 21:21:25 +0200
committerYehuda Sadeh <yehuda@hq.newdream.net>2010-10-15 19:41:46 +0200
commitb378cb4899e78d1d1e5b81f376a2536e56fe54c4 (patch)
tree0f4df9fe8dd8f4c0df23e3c3a6dc5584c5deaf4a
parentconf: only set sig handler if wasn't set already (diff)
downloadceph-b378cb4899e78d1d1e5b81f376a2536e56fe54c4.tar.xz
ceph-b378cb4899e78d1d1e5b81f376a2536e56fe54c4.zip
Add RGW_PRINT_CONTINUE to control wether we print the 100-continue header
Signed-off-by: Yehuda Sadeh <yehuda@hq.newdream.net>
-rw-r--r--src/rgw/rgw_rest.cc7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/rgw/rgw_rest.cc b/src/rgw/rgw_rest.cc
index 39dc63d27ed..44b6a4b637a 100644
--- a/src/rgw/rgw_rest.cc
+++ b/src/rgw/rgw_rest.cc
@@ -649,8 +649,11 @@ void RGWHandler_REST::provider_init_state()
s->copy_source = FCGX_GetParam("HTTP_X_AMZ_COPY_SOURCE", s->fcgx->envp);
s->http_auth = FCGX_GetParam("HTTP_AUTHORIZATION", s->fcgx->envp);
- const char *expect = FCGX_GetParam("HTTP_EXPECT", s->fcgx->envp);
- s->expect_cont = (expect && !strcasecmp(expect, "100-continue"));
+ const char *cgi_env_continue = FCGX_GetParam("RGW_PRINT_CONTINUE", s->fcgx->envp);
+ if (cgi_env_continue != NULL && strcasecmp(cgi_env_continue, "On") == 0) {
+ const char *expect = FCGX_GetParam("HTTP_EXPECT", s->fcgx->envp);
+ s->expect_cont = (expect && !strcasecmp(expect, "100-continue"));
+ }
}
static bool is_acl_op(struct req_state *s)