QHttpServerHttp1ProtocolHandler: fix UB (const_cast object originally marked as const)


Despite disconnect() taking Connection by cref, the function casts
away const. That is UB if the object being passed was originally
marked as const. In most cases, it isn't, but here, it actually was.

Fix by removing the const from the Connection members.

Amends f8c23436377c0c25650ca5834b01a6784f395ab0 (6.8) for the first
two and ea669306b2f46be6e07a67a2cb0ace92484abc0a (picked to 6.8) for
the third member.

Task-number: QTBUG-144929
Pick-to: 6.11 6.10 6.8
Change-Id: Ibd2ff9070235ae40ed73ac1a984b2014c499ced3
Reviewed-by: Fabian Kosmale <fabian.kosmale@qt.io>
commita5ad0a2ca6af01ce4e3b238c95b2ccbe1fabeff8
parent54a526c3847bc12f712bc6e7c2023224e0182d1a
authorMarc Mutz <marc.mutz@qt.io>
committerMarc Mutz <marc.mutz@qt.io>
commit timeWed, 25 Mar 2026 16:00:27 +0100