More error handling code on mysqlGetPad().