Fix oopsie in manual counting.

This was causing my server to die with an odd error message. It could be more robust, but then
again it's unlikely to change again.