mirror of
https://github.com/ceph/ceph
synced 2025-02-24 19:47:44 +00:00
rgw: drop dump_uri_from_state() which isn't used anymore.
Signed-off-by: Radoslaw Zarzynski <rzarzyns@redhat.com>
This commit is contained in:
parent
98a38f408a
commit
02b3726eb0
@ -439,31 +439,6 @@ void dump_bucket_from_state(struct req_state *s)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void dump_uri_from_state(struct req_state *s)
|
|
||||||
{
|
|
||||||
if (strcmp(s->info.request_uri.c_str(), "/") == 0) {
|
|
||||||
|
|
||||||
string location = "http://";
|
|
||||||
string server = s->info.env->get("SERVER_NAME", "<SERVER_NAME>");
|
|
||||||
location.append(server);
|
|
||||||
location += "/";
|
|
||||||
if (!s->bucket_name.empty()) {
|
|
||||||
if (!s->bucket_tenant.empty()) {
|
|
||||||
location += s->bucket_tenant;
|
|
||||||
location += ":";
|
|
||||||
}
|
|
||||||
location += s->bucket_name;
|
|
||||||
location += "/";
|
|
||||||
if (!s->object.empty()) {
|
|
||||||
location += s->object.name;
|
|
||||||
dump_header(s, "Location", location);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
dump_header_quoted(s, "Location", s->info.request_uri);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
void dump_redirect(struct req_state * const s, const std::string& redirect)
|
void dump_redirect(struct req_state * const s, const std::string& redirect)
|
||||||
{
|
{
|
||||||
return dump_header_if_nonempty(s, "Location", redirect);
|
return dump_header_if_nonempty(s, "Location", redirect);
|
||||||
|
@ -733,7 +733,6 @@ extern void list_all_buckets_end(struct req_state *s);
|
|||||||
extern void dump_time(struct req_state *s, const char *name, real_time *t);
|
extern void dump_time(struct req_state *s, const char *name, real_time *t);
|
||||||
extern std::string dump_time_to_str(const real_time& t);
|
extern std::string dump_time_to_str(const real_time& t);
|
||||||
extern void dump_bucket_from_state(struct req_state *s);
|
extern void dump_bucket_from_state(struct req_state *s);
|
||||||
extern void dump_uri_from_state(struct req_state *s);
|
|
||||||
extern void dump_redirect(struct req_state *s, const string& redirect);
|
extern void dump_redirect(struct req_state *s, const string& redirect);
|
||||||
extern bool is_valid_url(const char *url);
|
extern bool is_valid_url(const char *url);
|
||||||
extern void dump_access_control(struct req_state *s, const char *origin,
|
extern void dump_access_control(struct req_state *s, const char *origin,
|
||||||
|
Loading…
Reference in New Issue
Block a user