mirror of
https://github.com/moby/moby.git
synced 2026-01-11 18:51:37 +00:00
download-frozen-image-v2: handle 307 responses without decimal
Correctly parse HTTP response that doesn't contain an HTTP version with a decimal place: ``` < HTTP/2 307 ``` The previous version would only match strings like `HTTP/2.0 307`. Signed-off-by: Paweł Gronowski <pawel.gronowski@docker.com>
This commit is contained in:
@@ -81,7 +81,7 @@ fetch_blob() {
|
||||
-D-
|
||||
)"
|
||||
curlHeaders="$(echo "$curlHeaders" | tr -d '\r')"
|
||||
if grep -qE "^HTTP/[0-9].[0-9] 3" <<< "$curlHeaders"; then
|
||||
if grep -qE "^HTTP/[0-9](.[0-9])* 3" <<< "$curlHeaders"; then
|
||||
rm -f "$targetFile"
|
||||
|
||||
local blobRedirect
|
||||
|
||||
Reference in New Issue
Block a user