mirror of
https://bitbucket.org/smil3y/katie.git
synced 2025-02-25 03:12:56 +00:00
make qt_error_string() argument non-optional
Signed-off-by: Ivailo Monev <xakepa10@laimg.moc>
This commit is contained in:
parent
a53986b0c2
commit
85077cc320
3 changed files with 2 additions and 5 deletions
|
@ -1368,9 +1368,6 @@ static QtMsgHandler handler = 0; // pointer to debug handler
|
|||
|
||||
QString qt_error_string(int errorCode)
|
||||
{
|
||||
if (Q_UNLIKELY(errorCode == -1))
|
||||
errorCode = errno;
|
||||
|
||||
switch (errorCode) {
|
||||
case EACCES:
|
||||
return QString::fromLatin1(QT_TRANSLATE_NOOP("QIODevice", "Permission denied"));
|
||||
|
|
|
@ -641,7 +641,7 @@ Q_CORE_EXPORT void qWarning(const char *, ...) /* print warning message */
|
|||
#endif
|
||||
;
|
||||
|
||||
Q_CORE_EXPORT QString qt_error_string(int errorCode = -1);
|
||||
Q_CORE_EXPORT QString qt_error_string(int errorCode);
|
||||
Q_CORE_EXPORT void qCritical(const char *, ...) /* print critical message */
|
||||
#if (defined(Q_CC_GNU) || defined(Q_CC_CLANG)) && !defined(__INSURE__)
|
||||
__attribute__ ((format (printf, 1, 2)))
|
||||
|
|
|
@ -825,7 +825,7 @@ qint64 QNativeSocketEngine::read(char *data, qint64 maxSize)
|
|||
if (!d->hasSetSocketError) {
|
||||
d->hasSetSocketError = true;
|
||||
d->socketError = QAbstractSocket::NetworkError;
|
||||
d->socketErrorString = qt_error_string();
|
||||
d->socketErrorString = qt_error_string(errno);
|
||||
}
|
||||
close();
|
||||
return -1;
|
||||
|
|
Loading…
Add table
Reference in a new issue