BackgroundCache: plug an Animation object leak

We need to return early in case the animation file is the same,
otherwise we'll create a new Animation object and leak the previous
one.

https://bugzilla.gnome.org/show_bug.cgi?id=739252
This commit is contained in:
Rui Matos 2014-10-27 16:45:31 +01:00
parent d2011f6d7f
commit deb651acbf

View File

@ -162,6 +162,7 @@ const BackgroundCache = new Lang.Class({
}));
GLib.Source.set_name_by_id(id, '[gnome-shell] params.onLoaded');
}
return;
}
let animation = new Animation({ filename: params.filename });