blob: ec8bdd23d9d6abdb70853872958fa6500b5a016c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
|
// Copyright (C) 2022 The Qt Company Ltd.
// SPDX-License-Identifier: LicenseRef-Qt-Commercial OR LGPL-3.0-only OR GPL-2.0-only OR GPL-3.0-only
#include "qpcsc_p.h"
QT_BEGIN_NAMESPACE
using namespace Qt::StringLiterals;
namespace QPcsc {
QString errorMessage(LONG error)
{
#ifdef Q_OS_WIN
return (u"0x%1"_s).arg(error, 8, 16, QLatin1Char('0'));
#else
return QString::fromUtf8(pcsc_stringify_error(error));
#endif
}
} // namespace QPcsc
qsizetype QPcscSlotName::nameSize(QPcscSlotName::CPtr p)
{
#ifdef Q_OS_WIN
return wcslen(p);
#else
return strlen(p);
#endif
}
QT_END_NAMESPACE
|