From 7e82cefb728df14e889334dcf26f13fd8a616a14 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?M=C3=A5rten=20Nordheim?= Date: Fri, 14 Jan 2022 12:51:40 +0100 Subject: [PATCH] QNetworkRequest: Document how Qt handles 301 and 302 status codes To make it explicit Pick-to: 6.3 6.2 5.15 Task-number: QTBUG-92909 Change-Id: I8f8dc99628168a566158acef72ae2a5e001eef88 Reviewed-by: Timur Pocheptsov --- src/network/access/qnetworkrequest.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/network/access/qnetworkrequest.cpp b/src/network/access/qnetworkrequest.cpp index de40b2c088e..8cc916b1531 100644 --- a/src/network/access/qnetworkrequest.cpp +++ b/src/network/access/qnetworkrequest.cpp @@ -410,6 +410,11 @@ QT_BEGIN_NAMESPACE for example, to ask the user whether to accept the redirect, or to decide based on some app-specific configuration. + + \note When Qt handles redirects it will, for legacy and compatibility + reasons, issue the redirected request using GET when the server returns + a 301 or 302 response, regardless of the original method used, unless it was + HEAD. */ /*!