Re: [Wireshark-dev] MSVC gives warnings "qt_ui_utils.cpp(208, 25): warning C4996: 'QProcess::startDetached'"

2022-02-11 Thread Roland Knall
Which was used in the past, but that function has other issues (opening the 
users documents if the trace file path contains spaces)

I am looking into it. Empty StringList seems to solve it, but had not been able 
to test it properly yet

Cheers

> Am 11.02.2022 um 11:35 schrieb Graham Bloice :
> 
> 
> From the online Qt docs:
> bool QProcess::startDetached(const QString )
> 
> This function is obsolete. It is provided to keep old source code working. We 
> strongly advise against using it in new code.
> 
> Hence the MSVC warning, C4996 for a function that's marked as deprecated.  
> According to the Qt docs you should be using the more extensive overload:
> bool QProcess::startDetached(const QString , const QStringList 
> , const QString  = QString(), qint64 *pid = 
> nullptr)
> 
> and you'll have to provide the arguments parameter, even if it's an empty 
> QStringList.
> 
>> On Fri, 11 Feb 2022 at 10:15, Anders Broman via Wireshark-dev 
>>  wrote:
>> Hi,
>> 
>> Latest released one
>> 
>> C:\Qt\5.15.2
>> 
>> Regards
>> 
>> Anders
>> 
>>  
>> 
>> From: Roland Knall  
>> Sent: den 11 februari 2022 11:12
>> To: Developer support list for Wireshark 
>> Cc: Anders Broman 
>> Subject: Re: [Wireshark-dev] MSVC gives warnings "qt_ui_utils.cpp(208, 25): 
>> warning C4996: 'QProcess::startDetached'"
>> 
>>  
>> 
>> Which Qt version are you on?
>> 
>>  
>> 
>> Am Fr., 11. Feb. 2022 um 11:06 Uhr schrieb Anders Broman via Wireshark-dev 
>> :
>> 
>> Hi,
>> 
>> Just built and got the following warning:
>> 
>>  
>> 
>>  ..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996: 
>> 'QProcess::startDetached': Use QProcess::startDetached(const QString 
>> , const QStringList ) instead 
>> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>> 
>>..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996: success = 
>> QProcess::startDetached(command); 
>> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>> 
>>..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996:
>>  ^ [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>> 
>>  
>> 
>> 1 Warning(s)
>> 
>>  
>> 
>> Regards
>> 
>> Anders
>> 
>> ___
>> Sent via:Wireshark-dev mailing list 
>> Archives:https://www.wireshark.org/lists/wireshark-dev
>> Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
>>  mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe
>> 
>> ___
>> Sent via:Wireshark-dev mailing list 
>> Archives:https://www.wireshark.org/lists/wireshark-dev
>> Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
>>  mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe
> 
> 
> -- 
> Graham Bloice
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe


Re: [Wireshark-dev] MSVC gives warnings "qt_ui_utils.cpp(208, 25): warning C4996: 'QProcess::startDetached'"

2022-02-11 Thread Graham Bloice
>From the online Qt docs
<https://doc.qt.io/qt-5/qprocess-obsolete.html#startDetached-2>:
bool QProcess::startDetached(const QString
<https://doc.qt.io/qt-5/qstring.html> &*command*)
<https://doc.qt.io/qt-5/qprocess-obsolete.html#startDetached-2>

This function is obsolete. It is provided to keep old source code working.
We strongly advise against using it in new code.
Hence the MSVC warning, C4996 for a function that's marked as deprecated.
According to the Qt docs you should be using the more extensive overload:
bool QProcess::startDetached(const QString
<https://doc.qt.io/qt-5/qstring.html> &*program*, const QStringList
<https://doc.qt.io/qt-5/qstringlist.html> &*arguments*, const QString
<https://doc.qt.io/qt-5/qstring.html> &*workingDirectory* = QString(),
qint64 <https://doc.qt.io/qt-5/qtglobal.html#qint64-typedef> **pid* =
nullptr)
and you'll have to provide the arguments parameter, even if it's an empty
QStringList.

On Fri, 11 Feb 2022 at 10:15, Anders Broman via Wireshark-dev <
wireshark-dev@wireshark.org> wrote:

> Hi,
>
> Latest released one
>
> C:\Qt\5.15.2
>
> Regards
>
> Anders
>
>
>
> *From:* Roland Knall 
> *Sent:* den 11 februari 2022 11:12
> *To:* Developer support list for Wireshark 
> *Cc:* Anders Broman 
> *Subject:* Re: [Wireshark-dev] MSVC gives warnings "qt_ui_utils.cpp(208,
> 25): warning C4996: 'QProcess::startDetached'"
>
>
>
> Which Qt version are you on?
>
>
>
> Am Fr., 11. Feb. 2022 um 11:06 Uhr schrieb Anders Broman via Wireshark-dev
> :
>
> Hi,
>
> Just built and got the following warning:
>
>
>
>  ..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996:
> 'QProcess::startDetached': Use QProcess::startDetached(const QString
> , const QStringList ) instead
> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>
>..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996: success
> = QProcess::startDetached(command);
> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>
>..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning
> C4996: ^
> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>
>
>
> 1 Warning(s)
>
>
>
> Regards
>
> Anders
>
> ___
> Sent via:Wireshark-dev mailing list 
> Archives:https://www.wireshark.org/lists/wireshark-dev
> Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
>  mailto:wireshark-dev-requ...@wireshark.org
> ?subject=unsubscribe
>
> ___
> Sent via:Wireshark-dev mailing list 
> Archives:https://www.wireshark.org/lists/wireshark-dev
> Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
>  mailto:wireshark-dev-requ...@wireshark.org
> ?subject=unsubscribe
>


-- 
Graham Bloice
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe


Re: [Wireshark-dev] MSVC gives warnings "qt_ui_utils.cpp(208, 25): warning C4996: 'QProcess::startDetached'"

2022-02-11 Thread Anders Broman via Wireshark-dev
Hi,

Latest released one

C:\Qt\5.15.2

Regards

Anders



From: Roland Knall 
Sent: den 11 februari 2022 11:12
To: Developer support list for Wireshark 
Cc: Anders Broman 
Subject: Re: [Wireshark-dev] MSVC gives warnings "qt_ui_utils.cpp(208, 25): 
warning C4996: 'QProcess::startDetached'"



Which Qt version are you on?



Am Fr., 11. Feb. 2022 um 11:06 Uhr schrieb Anders Broman via Wireshark-dev 
mailto:wireshark-dev@wireshark.org> >:

Hi,

Just built and got the following warning:



 ..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996: 
'QProcess::startDetached': Use QProcess::startDetached(const QString , 
const QStringList ) instead 
[C:\Development\wsbuild64\ui\qt\qtui.vcxproj]

   ..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996: success = 
QProcess::startDetached(command); 
[C:\Development\wsbuild64\ui\qt\qtui.vcxproj]

   ..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996: 
^ [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]



1 Warning(s)



Regards

Anders

___
Sent via:Wireshark-dev mailing list mailto:wireshark-dev@wireshark.org> >
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org 
<mailto:wireshark-dev-requ...@wireshark.org> ?subject=unsubscribe



smime.p7s
Description: S/MIME cryptographic signature
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe


Re: [Wireshark-dev] MSVC gives warnings "qt_ui_utils.cpp(208, 25): warning C4996: 'QProcess::startDetached'"

2022-02-11 Thread Roland Knall
Which Qt version are you on?

Am Fr., 11. Feb. 2022 um 11:06 Uhr schrieb Anders Broman via Wireshark-dev <
wireshark-dev@wireshark.org>:

> Hi,
>
> Just built and got the following warning:
>
>
>
>  ..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996:
> 'QProcess::startDetached': Use QProcess::startDetached(const QString
> , const QStringList ) instead
> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>
>..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning C4996: success
> = QProcess::startDetached(command);
> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>
>..\ui\qt\utils\qt_ui_utils.cpp(208,25): warning
> C4996: ^
> [C:\Development\wsbuild64\ui\qt\qtui.vcxproj]
>
>
>
> 1 Warning(s)
>
>
>
> Regards
>
> Anders
> ___
> Sent via:Wireshark-dev mailing list 
> Archives:https://www.wireshark.org/lists/wireshark-dev
> Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
>  mailto:wireshark-dev-requ...@wireshark.org
> ?subject=unsubscribe
>
___
Sent via:Wireshark-dev mailing list 
Archives:https://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://www.wireshark.org/mailman/options/wireshark-dev
 mailto:wireshark-dev-requ...@wireshark.org?subject=unsubscribe