forked from qt-creator/qt-creator
Utils: Silence MSVC deprecation warnings in tst_qtcprocess
warning: C4996: 'setmode': The POSIX name for this item is deprecated. Instead, use the ISO C and C++ conformant name: _setmode. See online help for details. ...same for 'fileno' Change-Id: I85090b65532b17b535914b88de835d718f654f6a Reviewed-by: <github-actions-qt-creator@cristianadam.eu> Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
This commit is contained in:
@@ -1017,7 +1017,7 @@ void tst_QtcProcess::LineCallback::main()
|
|||||||
{
|
{
|
||||||
#ifdef Q_OS_WIN
|
#ifdef Q_OS_WIN
|
||||||
// Prevent \r\n -> \r\r\n translation.
|
// Prevent \r\n -> \r\r\n translation.
|
||||||
setmode(fileno(stderr), O_BINARY);
|
_setmode(_fileno(stderr), O_BINARY);
|
||||||
#endif
|
#endif
|
||||||
fprintf(stderr, "%s", QByteArray(lineCallbackData).replace('|', "").data());
|
fprintf(stderr, "%s", QByteArray(lineCallbackData).replace('|', "").data());
|
||||||
exit(0);
|
exit(0);
|
||||||
|
Reference in New Issue
Block a user