diff options
author | Christian Grothoff <christian@grothoff.org> | 2011-12-14 13:36:23 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2011-12-14 13:36:23 +0000 |
commit | 6ac444351418f5b15919c827ee418855656f6d14 (patch) | |
tree | 556fcdfed3b0314eeae18ee6bd34316a25aab099 /src/include/gnunet_stream_lib.h | |
parent | e8609f2fc7dfb7347398f09aed6446b30a77a700 (diff) | |
download | gnunet-6ac444351418f5b15919c827ee418855656f6d14.tar.gz gnunet-6ac444351418f5b15919c827ee418855656f6d14.zip |
-api improvement
Diffstat (limited to 'src/include/gnunet_stream_lib.h')
-rw-r--r-- | src/include/gnunet_stream_lib.h | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/src/include/gnunet_stream_lib.h b/src/include/gnunet_stream_lib.h index f0110bbb3..df5739cfe 100644 --- a/src/include/gnunet_stream_lib.h +++ b/src/include/gnunet_stream_lib.h | |||
@@ -211,8 +211,10 @@ GNUNET_STREAM_write (struct GNUNET_STREAM_Socket *socket, | |||
211 | * @param status the status of the stream at the time this function is called | 211 | * @param status the status of the stream at the time this function is called |
212 | * @param data traffic from the other side | 212 | * @param data traffic from the other side |
213 | * @param size the number of bytes available in data read | 213 | * @param size the number of bytes available in data read |
214 | * @return number of bytes of processed from 'data' (any data remaining should be | ||
215 | * given to the next time the read processor is called). | ||
214 | */ | 216 | */ |
215 | typedef void (*GNUNET_STREAM_DataProcessor) (void *cls, | 217 | typedef size_t (*GNUNET_STREAM_DataProcessor) (void *cls, |
216 | enum GNUNET_STREAM_Status status, | 218 | enum GNUNET_STREAM_Status status, |
217 | const char *data, | 219 | const char *data, |
218 | size_t size); | 220 | size_t size); |
@@ -223,7 +225,7 @@ typedef void (*GNUNET_STREAM_DataProcessor) (void *cls, | |||
223 | * | 225 | * |
224 | * @param socket the socket representing a stream | 226 | * @param socket the socket representing a stream |
225 | * @param timeout the timeout period | 227 | * @param timeout the timeout period |
226 | * @param proc function to call with data | 228 | * @param proc function to call with data (once only) |
227 | * @param proc_cls the closure for proc | 229 | * @param proc_cls the closure for proc |
228 | * @return handle to cancel the operation | 230 | * @return handle to cancel the operation |
229 | */ | 231 | */ |