* drop_on_error config param - if server throws error the connection
will not be reused but dropped. Defaults to 1.
+ = Fixes =
+
+ * SHOW SOCKETS/CLIENTS/SERVERS: Don't crash if socket has no buffer.
+
2008-07-29 - PgBouncer 1.2 - "Ordinary Magic Flute"
PgBouncer 1.2 now requires libevent version 1.3b or newer.
static void socket_row(PktBuf *buf, PgSocket *sk, const char *state, bool debug)
{
- int pkt_avail = iobuf_amount_parse(sk->sbuf.io);
- int send_avail = iobuf_amount_pending(sk->sbuf.io);
+ int pkt_avail = sk->sbuf.io ? iobuf_amount_parse(sk->sbuf.io) : 0;
+ int send_avail = sk->sbuf.io ? iobuf_amount_pending(sk->sbuf.io) : 0;
char ptrbuf[128], linkbuf[128];
char l_addr[32], r_addr[32];
IOBuf *io = sk->sbuf.io;