mirror of
https://github.com/s3fs-fuse/s3fs-fuse.git
synced 2025-01-11 00:21:45 +00:00
Merge pull request #334 from andrewgaul/bucket-host
Bucket host should include port and not path
This commit is contained in:
commit
e932583309
@ -111,7 +111,7 @@ static string url_to_host(const std::string &url)
|
|||||||
}
|
}
|
||||||
|
|
||||||
size_t idx;
|
size_t idx;
|
||||||
if ((idx = host.find(':')) != string::npos || (idx = host.find('/')) != string::npos) {
|
if ((idx = host.find('/')) != string::npos) {
|
||||||
return host.substr(0, idx);
|
return host.substr(0, idx);
|
||||||
} else {
|
} else {
|
||||||
return host;
|
return host;
|
||||||
@ -123,7 +123,7 @@ static string get_bucket_host()
|
|||||||
if(!pathrequeststyle){
|
if(!pathrequeststyle){
|
||||||
return bucket + "." + url_to_host(host);
|
return bucket + "." + url_to_host(host);
|
||||||
}
|
}
|
||||||
return url_to_host(host) + "/" + bucket;
|
return url_to_host(host);
|
||||||
}
|
}
|
||||||
|
|
||||||
#if 0 // noused
|
#if 0 // noused
|
||||||
|
Loading…
Reference in New Issue
Block a user