From df76edb9f15ec9620e2c13dfb2053bb17bf2fcbf Mon Sep 17 00:00:00 2001 From: Christian Ehrlicher Date: Sat, 3 Aug 2024 11:09:18 +0200 Subject: [PATCH] SQL/ODBC: Fix calling SQLGetData() for old drivers Some old drivers don't return SQL_NO_DATA when all data was fetched which resulted in an infinite loop. The previous check does not work when we receive chunked data and the driver returns fewer bytes than the maximum buffer size. Therefore simply check for SQL_SUCCESS since according the msdn docs, SQL_SUCCESS_WITH_INFO must be returned when there is more data to fetch. This also avoids an additional call to SQLGetData() here. Pick-to: 6.8 6.7 6.5 Fixes: QTBUG-119753 Change-Id: I42ed194f3955a650e63615615fe82d785f324228 Reviewed-by: Thiago Macieira