smart: send a flush when we disconnect

The git server wants to hear a flush from us when we disconnect,
particularly when we want to perform a fetch but are up to date.

This fixes #2031.

---

I'm not sure if I'm explaining what we're doing here in a way that makes sense.