diff --git a/qrenderdoc/Windows/Dialogs/LiveCapture.cpp b/qrenderdoc/Windows/Dialogs/LiveCapture.cpp index c49f9def5..36154c332 100644 --- a/qrenderdoc/Windows/Dialogs/LiveCapture.cpp +++ b/qrenderdoc/Windows/Dialogs/LiveCapture.cpp @@ -24,6 +24,7 @@ #include "LiveCapture.h" #include +#include #include #include #include @@ -448,8 +449,15 @@ void LiveCapture::childUpdate() } } + // We only compare the child processes for a local context + const bool local = isLocal(); + // enumerate processes outside of the lock - QProcessList processes = QProcessInfo::enumerate(false); + QProcessList processes; + if(local) + { + processes = QProcessInfo::enumerate(false); + } // now since we're adding and removing, we lock around the whole rest of the function. It won't be // too slow. @@ -472,7 +480,7 @@ void LiveCapture::childUpdate() } } - if(!found) + if(!found && local) { if(m_Children[i].added) { @@ -1460,3 +1468,9 @@ void LiveCapture::connectionThreadEntry() connectionClosed(); }); } + +bool LiveCapture::isLocal() const +{ + return m_Hostname.isEmpty() || QHostInfo::localHostName() == m_Hostname || + QLatin1String("0.0.0.0") == m_Hostname || QHostAddress(m_Hostname).isLoopback(); +} diff --git a/qrenderdoc/Windows/Dialogs/LiveCapture.h b/qrenderdoc/Windows/Dialogs/LiveCapture.h index 8a23beb66..87ef2e343 100644 --- a/qrenderdoc/Windows/Dialogs/LiveCapture.h +++ b/qrenderdoc/Windows/Dialogs/LiveCapture.h @@ -157,6 +157,8 @@ private: bool checkAllowDelete(); void deleteCaptureUnprompted(QListWidgetItem *item); + bool isLocal() const; + Ui::LiveCapture *ui; ICaptureContext &m_Ctx; QString m_Hostname;