diff options
author | Martin Kaiser <wireshark@kaiser.cx> | 2016-12-24 13:16:38 +0100 |
---|---|---|
committer | Alexis La Goutte <alexis.lagoutte@gmail.com> | 2016-12-24 13:54:25 +0000 |
commit | 0c4d074f2835711c10b41ca72c507c03b4c9cc55 (patch) | |
tree | 51664336dfe2890f3718bd9b6916fb7895ffd66d /ui | |
parent | 55549f5ac823e3081ee7a05d0156e7f848872ebd (diff) |
extcap_options_dialog: fix compilation with Qt4
Qt4's QFileInfo::exist() can only be used with an existing QFileInfo
object. The version that accepts the file name as paramter was
introduced in Qt5.
Create a temporary QFileInfo object and call exists() on this object.
Change-Id: I162cc22ecba61b2c2f16f9f0916b0db7969abb51
Reviewed-on: https://code.wireshark.org/review/19408
Reviewed-by: Martin Kaiser <wireshark@kaiser.cx>
Petri-Dish: Martin Kaiser <wireshark@kaiser.cx>
Tested-by: Petri Dish Buildbot <buildbot-no-reply@wireshark.org>
Reviewed-by: Alexis La Goutte <alexis.lagoutte@gmail.com>
Diffstat (limited to 'ui')
-rw-r--r-- | ui/qt/extcap_options_dialog.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ui/qt/extcap_options_dialog.cpp b/ui/qt/extcap_options_dialog.cpp index fceb2bc120..7dcf618c00 100644 --- a/ui/qt/extcap_options_dialog.cpp +++ b/ui/qt/extcap_options_dialog.cpp @@ -335,7 +335,8 @@ void ExtcapOptionsDialog::on_buttonBox_helpRequested() /* The help information is a file url and has been provided as-is by the extcap. Before attempting to open the it, check if it actually exists. */ - if ( ! QFileInfo::exists(help_url.path()) ) + QFileInfo help_file(help_url.path()); + if ( !help_file.exists() ) { QMessageBox::warning(this, tr("Extcap Help cannot be found"), QString(tr("The help for the extcap interface %1 cannot be found. Given file: %2")) |