diff options
author | Lars-Dominik Braun <lars@6xq.net> | 2011-09-19 20:52:45 +0200 |
---|---|---|
committer | Lars-Dominik Braun <lars@6xq.net> | 2011-11-09 20:10:03 +0100 |
commit | e2e80f0890ec52ad7856850761bff0840bbb65b4 (patch) | |
tree | 9c96bc61399828e48157e12c474dd1bb740ed60b /src/libwaitress/waitress.h | |
parent | e0b076eb06f605cae91022d2e644cda2e5ea5676 (diff) | |
download | pianobar-e2e80f0890ec52ad7856850761bff0840bbb65b4.tar.gz pianobar-e2e80f0890ec52ad7856850761bff0840bbb65b4.tar.bz2 pianobar-e2e80f0890ec52ad7856850761bff0840bbb65b4.zip |
waitress: handler return values
Diffstat (limited to 'src/libwaitress/waitress.h')
-rw-r--r-- | src/libwaitress/waitress.h | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/src/libwaitress/waitress.h b/src/libwaitress/waitress.h index f3aff55..a5aae32 100644 --- a/src/libwaitress/waitress.h +++ b/src/libwaitress/waitress.h @@ -39,6 +39,13 @@ typedef enum { WAITRESS_CB_RET_OK, } WaitressCbReturn_t; +typedef enum { + WAITRESS_HANDLER_CONTINUE, + WAITRESS_HANDLER_DONE, + WAITRESS_HANDLER_ERR, + WAITRESS_HANDLER_ABORTED, +} WaitressHandlerReturn_t; + typedef struct { char *url; /* splitted url, unusable */ const char *user; @@ -64,7 +71,7 @@ typedef struct { struct { size_t contentLength, contentReceived, chunkSize; /* first argument is WaitressHandle_t, but that's not defined here */ - WaitressCbReturn_t (*dataHandler) (void *, char *, size_t); + WaitressHandlerReturn_t (*dataHandler) (void *, char *, size_t); } request; } WaitressHandle_t; @@ -82,6 +89,7 @@ typedef enum { WAITRESS_RET_TIMEOUT, WAITRESS_RET_READ_ERR, WAITRESS_RET_CONNECTION_CLOSED, + WAITRESS_RET_DECODING_ERR, } WaitressReturn_t; void WaitressInit (WaitressHandle_t *); |