Session chooser allows to create new session with the same name as that of an existing session overwriting the exisiting session
Hello!
While creating a new session from Session chooser dialog, session chooser doesn't check if the session name already exists. This overwrites the existing session when the new session having the same name is saved (Either manually clicking "Save session" or automatically on logout)
Steps to reproduce:
- Create couple of sessions foo, bar, baz etc.
- Create new session having same name as that of an existing session
foo
If user has handful of sessions in session list, she might use existing session name while creating a new session. Session chooser should show error message "Session already exists" instead of overwriting the existing session.
This is much like adduser
:
$ sudo adduser root
adduser: The user `root' already exists.
$
I believe the fix is needed right after https://gitlab.xfce.org/xfce/xfce4-session/-/blob/master/xfce4-session/xfsm-manager.c#L725
Thanks!