xfce4session: fix a bug causing random crashes

This should work, finally https://bugzilla.xfce.org/show_bug.cgi?id=9709