Mercurial > hg > th-libs
diff th_network.h @ 735:31bc1ed07cf5
Renaming BOOL->bool and TRUE/FALSE to true/false, and using stdbool.h if available.
author | Matti Hamalainen <ccr@tnsp.org> |
---|---|
date | Wed, 07 Dec 2022 12:14:39 +0200 |
parents | 29e44a58bc73 |
children | db1a132c7754 |
line wrap: on
line diff
--- a/th_network.h Wed Dec 07 11:58:54 2022 +0200 +++ b/th_network.h Wed Dec 07 12:14:39 2022 +0200 @@ -14,7 +14,7 @@ #ifdef TH_PLAT_WINDOWS -# define __OBJC_BOOL // A nasty hack +# define __OBJC_bool // A nasty hack # include <windows.h> # include <winsock.h> typedef uint16_t in_port_t; @@ -157,11 +157,11 @@ int th_conn_pull(th_conn_t *); int th_conn_send_buf(th_conn_t *, const void *buf, const size_t len); int th_conn_send_growbuf(th_conn_t *, th_growbuf_t *buf); -BOOL th_conn_check(th_conn_t *); +bool th_conn_check(th_conn_t *); -BOOL th_conn_buf_check(th_conn_t *conn, size_t n); -BOOL th_conn_buf_skip(th_conn_t *conn, size_t n); +bool th_conn_buf_check(th_conn_t *conn, size_t n); +bool th_conn_buf_skip(th_conn_t *conn, size_t n); int th_conn_buf_strncmp(th_conn_t *conn, const char *str, const size_t n); int th_conn_buf_strcmp(th_conn_t *conn, const char *str); char * th_conn_buf_strstr(th_conn_t *conn, const char *str);