pgsql improvements
pgsql improvements

* set pgsql->result to NULL when we freed it
* drain the connection pipe just in case in pgsql_conn_release()

korusdipl/kore,fourdollars/kore,bonifaido/kore,jorisvink/kore,hhua/kore,hhua/kore,sinemetu1/kore,hhua/kore,bonifaido/kore,bonifaido/kore,jorisvink/kore,zhcy/kore