Reproduce: 1. start tmux 2. open a bunch of windows, close them all 3. kill server 4. restart tmux 5 There is only one tmux window, it should be 0 but it will be a number from the saved session.