forked from TrueCloudLab/frostfs-s3-gw
[#594] Fix unmarshal cors: expected element in name space error
Signed-off-by: Pavel Pogodaev <p.pogodaev@yadro.com>
This commit is contained in:
parent
0cab76d01e
commit
bc975989de
5 changed files with 34 additions and 9 deletions
|
@ -79,6 +79,7 @@ type configMock struct {
|
|||
bypassContentEncodingInChunks bool
|
||||
md5Enabled bool
|
||||
tlsTerminationHeader string
|
||||
useDefaultXMLNS bool
|
||||
}
|
||||
|
||||
func (c *configMock) DefaultPlacementPolicy(_ string) netmap.PlacementPolicy {
|
||||
|
@ -99,7 +100,11 @@ func (c *configMock) DefaultCopiesNumbers(_ string) []uint32 {
|
|||
}
|
||||
|
||||
func (c *configMock) NewXMLDecoder(r io.Reader, _ string) *xml.Decoder {
|
||||
return xml.NewDecoder(r)
|
||||
dec := xml.NewDecoder(r)
|
||||
if c.useDefaultXMLNS {
|
||||
dec.DefaultSpace = "http://s3.amazonaws.com/doc/2006-03-01/"
|
||||
}
|
||||
return dec
|
||||
}
|
||||
|
||||
func (c *configMock) BypassContentEncodingInChunks(_ string) bool {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue