1
0
mirror of https://github.com/moby/moby.git synced 2025-12-09 10:01:25 +03:00

Allowing resize tty to only work when container is started

Addresses #8728

Signed-off-by: Srini Brahmaroutu <srbrahma@us.ibm.com>
This commit is contained in:
Srini Brahmaroutu
2014-10-23 20:30:18 +00:00
parent 8b40d385b5
commit 78a272ce14
3 changed files with 58 additions and 1 deletions

View File

@@ -254,7 +254,8 @@ func sockRequest(method, endpoint string) ([]byte, error) {
}
defer resp.Body.Close()
if resp.StatusCode != http.StatusOK {
return nil, fmt.Errorf("received status != 200 OK: %s", resp.Status)
body, _ := ioutil.ReadAll(resp.Body)
return body, fmt.Errorf("received status != 200 OK: %s", resp.Status)
}
return ioutil.ReadAll(resp.Body)