Added a session timeout detection attribute - need to test it.

Possibly noticed a bug where a slot is being filled when total -1, so 9 is filling a 10 slot etc. Look into this.