force regeneration of SID for non-existing session

Disclaimer: this change was thoroughly untested by me :)