forked from osmocom/wireshark
Qt: fix build without libpcap
Change-Id: I89a2f9a21a17a318529c7f0785ab60385fe08dcf Fixes: v2.3.0rc0-1445-g414c132 ("Qt: Handle retranslation events in the main window") Reviewed-on: https://code.wireshark.org/review/18746 Reviewed-by: Peter Wu <peter@lekensteyn.nl> Tested-by: Peter Wu <peter@lekensteyn.nl> Reviewed-by: Gerald Combs <gerald@wireshark.org>
This commit is contained in:
parent
65ab2a9701
commit
55fbb6387a
|
@ -418,9 +418,7 @@ void MainStatusBar::showCaptureStatistics()
|
|||
{
|
||||
QString packets_str;
|
||||
|
||||
#ifndef HAVE_LIBPCAP
|
||||
Q_UNUSED(cap_session)
|
||||
#else
|
||||
#ifdef HAVE_LIBPCAP
|
||||
/* Do we have any packets? */
|
||||
if (cs_fixed_ && cs_count_ > 0) {
|
||||
packets_str.append(QString(tr("Packets: %1"))
|
||||
|
@ -472,7 +470,9 @@ void MainStatusBar::updateCaptureStatistics(capture_session *cap_session)
|
|||
{
|
||||
cs_fixed_ = false;
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
#ifndef HAVE_LIBPCAP
|
||||
Q_UNUSED(cap_session)
|
||||
#else
|
||||
if ((!cap_session || cap_session->cf == cap_file_) && cap_file_ && cap_file_->count) {
|
||||
cs_count_ = cap_file_->count;
|
||||
} else {
|
||||
|
@ -487,7 +487,9 @@ void MainStatusBar::updateCaptureFixedStatistics(capture_session *cap_session)
|
|||
{
|
||||
cs_fixed_ = true;
|
||||
|
||||
#ifdef HAVE_LIBPCAP
|
||||
#ifndef HAVE_LIBPCAP
|
||||
Q_UNUSED(cap_session)
|
||||
#else
|
||||
if (cap_session && cap_session->count) {
|
||||
cs_count_ = cap_session->count;
|
||||
} else {
|
||||
|
|
Loading…
Reference in New Issue