@@ -124,7 +124,7 @@ pg_GSS_continue(PGconn *conn, int payloadlen)
124124 * first or subsequent packet, just send the same kind of password
125125 * packet.
126126 */
127- if (pqPacketSend (conn , 'p' ,
127+ if (pqPacketSend (conn , PqMsg_GSSResponse ,
128128 goutbuf .value , goutbuf .length ) != STATUS_OK )
129129 {
130130 gss_release_buffer (& lmin_s , & goutbuf );
@@ -324,7 +324,7 @@ pg_SSPI_continue(PGconn *conn, int payloadlen)
324324 */
325325 if (outbuf .pBuffers [0 ].cbBuffer > 0 )
326326 {
327- if (pqPacketSend (conn , 'p' ,
327+ if (pqPacketSend (conn , PqMsg_GSSResponse ,
328328 outbuf .pBuffers [0 ].pvBuffer , outbuf .pBuffers [0 ].cbBuffer ))
329329 {
330330 FreeContextBuffer (outbuf .pBuffers [0 ].pvBuffer );
@@ -683,7 +683,7 @@ pg_SASL_continue(PGconn *conn, int payloadlen, bool final)
683683 /*
684684 * Send the SASL response to the server.
685685 */
686- res = pqPacketSend (conn , 'p' , output , outputlen );
686+ res = pqPacketSend (conn , PqMsg_SASLResponse , output , outputlen );
687687 free (output );
688688
689689 if (res != STATUS_OK )
@@ -754,7 +754,8 @@ pg_password_sendauth(PGconn *conn, const char *password, AuthRequest areq)
754754 default :
755755 return STATUS_ERROR ;
756756 }
757- ret = pqPacketSend (conn , 'p' , pwd_to_send , strlen (pwd_to_send ) + 1 );
757+ ret = pqPacketSend (conn , PqMsg_PasswordMessage ,
758+ pwd_to_send , strlen (pwd_to_send ) + 1 );
758759 free (crypt_pwd );
759760 return ret ;
760761}
0 commit comments