Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Backports:SLE-15-SP4:RebuildFactoryUpdates
kdb
Fix-build-with-newer-Qt.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File Fix-build-with-newer-Qt.patch of Package kdb
From 3a31ad05fcc7682bf3b65143af99fdb9b2e1e248 Mon Sep 17 00:00:00 2001 From: Nicolas Fella <nicolas.fella@gmx.de> Date: Mon, 16 Nov 2020 16:41:27 +0100 Subject: [PATCH] Fix build with newer Qt (cherry picked from commit b36d74f13a1421437a725fb74502c993c359392a) --- src/KDb.cpp | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) diff --git a/src/KDb.cpp b/src/KDb.cpp index 5c3b601f..ee92c2ee 100644 --- a/src/KDb.cpp +++ b/src/KDb.cpp @@ -1635,33 +1635,33 @@ QString KDb::escapeBLOB(const QByteArray& array, BLOBEscapingType type) for (int i = 0; i < size; i++) { const unsigned char val = array[i]; if (val < 32 || val >= 127 || val == 39 || val == 92) { - str[new_length++] = '\\'; - str[new_length++] = '\\'; - str[new_length++] = '0' + val / 64; - str[new_length++] = '0' + (val % 64) / 8; - str[new_length++] = '0' + val % 8; + str[new_length++] = QLatin1Char('\\'); + str[new_length++] = QLatin1Char('\\'); + str[new_length++] = QChar::fromLatin1('0' + val / 64); + str[new_length++] = QChar::fromLatin1('0' + (val % 64) / 8); + str[new_length++] = QChar::fromLatin1('0' + val % 8); } else { - str[new_length++] = val; + str[new_length++] = QChar::fromLatin1(val); } } } else { for (int i = 0; i < size; i++) { const unsigned char val = array[i]; - str[new_length++] = intToHexDigit(val / 16); - str[new_length++] = intToHexDigit(val % 16); + str[new_length++] = QChar::fromLatin1(intToHexDigit(val / 16)); + str[new_length++] = QChar::fromLatin1(intToHexDigit(val % 16)); } } if (type == BLOBEscapingType::XHex || type == BLOBEscapingType::Octal) { - str[new_length++] = '\''; + str[new_length++] = QLatin1Char('\''); } else if (type == BLOBEscapingType::ByteaHex) { - str[new_length++] = '\''; - str[new_length++] = ':'; - str[new_length++] = ':'; - str[new_length++] = 'b'; - str[new_length++] = 'y'; - str[new_length++] = 't'; - str[new_length++] = 'e'; - str[new_length++] = 'a'; + str[new_length++] = QLatin1Char('\''); + str[new_length++] = QLatin1Char(':'); + str[new_length++] = QLatin1Char(':'); + str[new_length++] = QLatin1Char('b'); + str[new_length++] = QLatin1Char('y'); + str[new_length++] = QLatin1Char('t'); + str[new_length++] = QLatin1Char('e'); + str[new_length++] = QLatin1Char('a'); } return str; } -- GitLab
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor