fix(tray): Fix glib assertion when old property value is missing

xembedsniproxy sets WindowId as 'i' instead of 'u' and DBus::Proxy
ignores incorrectly typed value.
This commit is contained in:
Aleksei Bavshin 2019-05-20 05:55:13 -07:00
parent 316a9be656
commit afd291a566
1 changed files with 1 additions and 1 deletions

View File

@ -126,7 +126,7 @@ void Item::processUpdatedProperties(Glib::RefPtr<Gio::AsyncResult>& _result) {
for (const auto& [name, value] : properties) {
Glib::VariantBase old_value;
proxy_->get_cached_property(old_value, name);
if (!value.equal(old_value)) {
if (!old_value || !value.equal(old_value)) {
proxy_->set_cached_property(name, value);
setProperty(name, const_cast<Glib::VariantBase&>(value));
}