1
0
Fork 0
mirror of https://github.com/moby/moby.git synced 2022-11-09 12:21:53 -05:00

Merge pull request #4720 from vieux/fix_content-type_cp

fix content-type detection in docker cp
This commit is contained in:
Guillaume J. Charmes 2014-03-17 11:24:18 -07:00
commit d810218038

View file

@ -883,7 +883,7 @@ func postContainersCopy(eng *engine.Engine, version version.Version, w http.Resp
var copyData engine.Env var copyData engine.Env
if contentType := r.Header.Get("Content-Type"); contentType == "application/json" { if contentType := r.Header.Get("Content-Type"); MatchesContentType(contentType, "application/json") {
if err := copyData.Decode(r.Body); err != nil { if err := copyData.Decode(r.Body); err != nil {
return err return err
} }