Merge pull request #3413 from warwickmm/avoid_null_reference

Avoid potential null reference exception
This commit is contained in:
Rune Henriksen
2018-10-07 19:14:34 +02:00
committed by GitHub
@@ -333,9 +333,9 @@ namespace Duplicati.GUI.TrayIcon
m_isQuitting = true;
if (m_rumpsProcess != null && !m_rumpsProcess.HasExited)
{
m_toRumps.WriteNoWait(JsonConvert.SerializeObject(new {Action = "shutdown"}));
if (m_toRumps != null)
{
{
m_toRumps.WriteNoWait(JsonConvert.SerializeObject(new { Action = "shutdown" }));
m_toRumps.Dispose();
m_toRumps = null;
}