Prevent Cinnamon from segfaulting when changing the theme

This prevents a segfault that can happen when opening mockturtl's weather applet's popup (and maybe other applet's popups as well) after changing the theme.