From a98bf7b88926295d9c0c823a60c0cf7b8a981871 Mon Sep 17 00:00:00 2001 From: Sree Harsha Totakura Date: Wed, 16 Jan 2013 11:35:45 +0000 Subject: [PATCH] - doc - moved write_cont callback towarding beginning of GNUNET_STREAM_WriteHandle - rename stream_protocol.h to stream.h --- src/include/gnunet_stream_lib.h | 2 +- src/stream/Makefile.am | 2 +- src/stream/{stream_protocol.h => stream.h} | 8 ++++---- src/stream/stream_api.c | 14 +++++++------- 4 files changed, 13 insertions(+), 13 deletions(-) rename src/stream/{stream_protocol.h => stream.h} (97%) diff --git a/src/include/gnunet_stream_lib.h b/src/include/gnunet_stream_lib.h index 0acede1ac..056695ba3 100644 --- a/src/include/gnunet_stream_lib.h +++ b/src/include/gnunet_stream_lib.h @@ -301,7 +301,7 @@ struct GNUNET_STREAM_ReadHandle; /** * Tries to write the given data to the stream. The maximum size of data that - * can be written as part of a write operation is (64 * (64000 - sizeof (struct + * can be written per a write operation is ~ 4MB (64 * (64000 - sizeof (struct * GNUNET_STREAM_DataMessage))). If size is greater than this it is not an API * violation, however only the said number of maximum bytes will be written. * diff --git a/src/stream/Makefile.am b/src/stream/Makefile.am index 77f2d6d59..099469711 100644 --- a/src/stream/Makefile.am +++ b/src/stream/Makefile.am @@ -12,7 +12,7 @@ endif lib_LTLIBRARIES = libgnunetstream.la libgnunetstream_la_SOURCES = \ - stream_api.c stream_protocol.h + stream_api.c stream.h libgnunetstream_la_LIBADD = \ $(top_builddir)/src/mesh/libgnunetmesh.la \ $(top_builddir)/src/lockmanager/libgnunetlockmanager.la \ diff --git a/src/stream/stream_protocol.h b/src/stream/stream.h similarity index 97% rename from src/stream/stream_protocol.h rename to src/stream/stream.h index ca14d16ed..9b92a28ee 100644 --- a/src/stream/stream_protocol.h +++ b/src/stream/stream.h @@ -19,13 +19,13 @@ */ /** - * @file stream/stream_protocol.h + * @file stream/stream.h * @brief P2P protocol for the stream connections * @author Sree Harsha Totakura */ -#ifndef STREAM_PROTOCOL_H -#define STREAM_PROTOCOL_H +#ifndef STREAM_H +#define STREAM_H #ifdef __cplusplus extern "C" @@ -187,4 +187,4 @@ GNUNET_NETWORK_STRUCT_END } #endif -#endif /* STREAM_PROTOCOL_H */ +#endif /* STREAM.H */ diff --git a/src/stream/stream_api.c b/src/stream/stream_api.c index 4b86bece0..20df4aaf5 100644 --- a/src/stream/stream_api.c +++ b/src/stream/stream_api.c @@ -40,7 +40,7 @@ #include "gnunet_lockmanager_service.h" #include "gnunet_statistics_service.h" #include "gnunet_stream_lib.h" -#include "stream_protocol.h" +#include "stream.h" /** * Generic logging shorthand @@ -461,11 +461,6 @@ struct GNUNET_STREAM_WriteHandle */ struct GNUNET_STREAM_Socket *socket; - /** - * The packet_buffers associated with this Handle - */ - struct GNUNET_STREAM_DataMessage *messages[GNUNET_STREAM_ACK_BITMAP_BIT_LENGTH]; - /** * The write continuation callback */ @@ -476,6 +471,11 @@ struct GNUNET_STREAM_WriteHandle */ void *write_cont_cls; + /** + * The packet_buffers associated with this Handle + */ + struct GNUNET_STREAM_DataMessage *messages[GNUNET_STREAM_ACK_BITMAP_BIT_LENGTH]; + /** * The bitmap of this IOHandle; Corresponding bit for a message is set when * it has been acknowledged by the receiver @@ -3488,7 +3488,7 @@ GNUNET_STREAM_listen_close (struct GNUNET_STREAM_ListenSocket *lsocket) /** * Tries to write the given data to the stream. The maximum size of data that - * can be written as part of a write operation is (64 * (64000 - sizeof (struct + * can be written per a write operation is ~ 4MB (64 * (64000 - sizeof (struct * GNUNET_STREAM_DataMessage))). If size is greater than this it is not an API * violation, however only the said number of maximum bytes will be written. * -- 2.25.1