Commit 2d07f381 authored by Philip Withnall's avatar Philip Withnall

lib: Clear state in an error path

Ensure that the UhmServer’s internal state is unchanged if
uhm_server_start_trace_full() hits an error.
parent 5c29bbd3
......@@ -1636,6 +1636,7 @@ uhm_server_start_trace_full (UhmServer *self, GFile *trace_file, GError **error)
g_error_free (child_error);
uhm_server_stop (self);
g_clear_object (&priv->output_stream);
return;
}
......@@ -1650,6 +1651,8 @@ uhm_server_start_trace_full (UhmServer *self, GFile *trace_file, GError **error)
g_error_free (child_error);
g_clear_object (&priv->output_stream);
return;
}
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment