Handle connection messages separately
Handle connection messages separately

We currently use handle_messages() for handling all messages. However,
by separating out message handling during the connection phase and the
query phase we end up with two bits of code, each of which is simpler
than the single handle_messages() code.

kaniini/pg8000,kaniini/pg8000,realazthat/pg8000,realazthat/pg8000,tlocke/pg8000