MCPcopy Create free account
hub / github.com/apache/cloudberry / my_sock_write

Function my_sock_write

src/interfaces/libpq/fe-secure-openssl.c:1699–1727  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1697}
1698
1699static int
1700my_sock_write(BIO *h, const char *buf, int size)
1701{
1702 int res;
1703
1704 res = pqsecure_raw_write((PGconn *) BIO_get_app_data(h), buf, size);
1705 BIO_clear_retry_flags(h);
1706 if (res < 0)
1707 {
1708 /* If we were interrupted, tell caller to retry */
1709 switch (SOCK_ERRNO)
1710 {
1711#ifdef EAGAIN
1712 case EAGAIN:
1713#endif
1714#if defined(EWOULDBLOCK) && (!defined(EAGAIN) || (EWOULDBLOCK != EAGAIN))
1715 case EWOULDBLOCK:
1716#endif
1717 case EINTR:
1718 BIO_set_retry_write(h);
1719 break;
1720
1721 default:
1722 break;
1723 }
1724 }
1725
1726 return res;
1727}
1728
1729static BIO_METHOD *
1730my_BIO_s_socket(void)

Callers

nothing calls this directly

Calls 1

pqsecure_raw_writeFunction · 0.85

Tested by

no test coverage detected