Skip to content

Commit

Permalink
Update transport_interface.h to match coreMQTT (#79)
Browse files Browse the repository at this point in the history
* Update transport_interface.h to match coreMQTT

* Add TX to lexicon.txt
  • Loading branch information
aggarw13 authored Dec 8, 2020
1 parent 66dfa97 commit 6d53067
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions lexicon.txt
Original file line number Diff line number Diff line change
Expand Up @@ -237,6 +237,7 @@ transportsectionoverview
transportsend
transportstatus
transportstruct
tx
txt
uint
uri
Expand Down
7 changes: 6 additions & 1 deletion source/interface/transport_interface.h
Original file line number Diff line number Diff line change
Expand Up @@ -165,6 +165,7 @@ typedef struct NetworkContext NetworkContext_t;
*
* @return The number of bytes received or a negative value to indicate
* error.
*
* @note If no data is available on the network to read and no error
* has occurred, zero MUST be the return value. Zero MUST NOT be used
* if a network disconnection has occurred.
Expand All @@ -183,7 +184,11 @@ typedef int32_t ( * TransportRecv_t )( NetworkContext_t * pNetworkContext,
* @param[in] pBuffer Buffer containing the bytes to send over the network stack.
* @param[in] bytesToSend Number of bytes to send over the network.
*
* @return The number of bytes sent or a negative error code.
* @return The number of bytes sent or a negative value to indicate error.
*
* @note If no data is transmitted over the network due to a full TX buffer and
* no network error has occurred, this MUST return zero as the return value.
* Zero MUST NOT be returned if a network disconnection has occurred.
*/
/* @[define_transportsend] */
typedef int32_t ( * TransportSend_t )( NetworkContext_t * pNetworkContext,
Expand Down

0 comments on commit 6d53067

Please sign in to comment.