Function esp_idf_svc::sys::esp_tls_conn_write
source · pub unsafe extern "C" fn esp_tls_conn_write(
tls: *mut esp_tls,
data: *const c_void,
datalen: usize,
) -> isize
Expand description
@brief Write from buffer ‘data’ into specified tls connection.
@param[in] tls pointer to esp-tls as esp-tls handle. @param[in] data Buffer from which data will be written. @param[in] datalen Length of data buffer.
@return - >=0 if write operation was successful, the return value is the number of bytes actually written to the TLS/SSL connection. - <0 if write operation was not successful, because either an error occured or an action must be taken by the calling process. - ESP_TLS_ERR_SSL_WANT_READ/ ESP_TLS_ERR_SSL_WANT_WRITE. if the handshake is incomplete and waiting for data to be available for reading. In this case this functions needs to be called again when the underlying transport is ready for operation.