summaryrefslogtreecommitdiffstats
path: root/util/src
diff options
context:
space:
mode:
authorGravatar samisa2011-08-29 10:54:57 +0000
committerGravatar samisa2011-08-29 10:54:57 +0000
commitc45a19e8b2b2dab5dd73f74ba2bfb9f91fda2742 (patch)
tree4ea1a48ffc4c74e0a68aacdd8cafe17ef9f93232 /util/src
parentf14321f87f76c183693e0ed3f72adbd29d38c7a3 (diff)
downloadaxis2c-c45a19e8b2b2dab5dd73f74ba2bfb9f91fda2742.tar.gz
axis2c-c45a19e8b2b2dab5dd73f74ba2bfb9f91fda2742.tar.bz2
fixing the peek to support SSL by applying patch given in AXIS2C-1556.
git-svn-id: http://svn.apache.org/repos/asf/axis/axis2/c/core/trunk@1162726 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'util/src')
-rw-r--r--util/src/stream.c22
1 files changed, 22 insertions, 0 deletions
diff --git a/util/src/stream.c b/util/src/stream.c
index 1034a03..3f6a711 100644
--- a/util/src/stream.c
+++ b/util/src/stream.c
@@ -501,6 +501,7 @@ axutil_stream_create_socket(
stream->read = axutil_stream_read_socket;
stream->write = axutil_stream_write_socket;
stream->skip = axutil_stream_skip_socket;
+ stream->peek = axutil_stream_peek_socket;
stream->stream_type = AXIS2_STREAM_SOCKET;
stream->socket = socket;
stream->fp = NULL;
@@ -689,6 +690,16 @@ axutil_stream_set_skip(
return AXIS2_SUCCESS;
}
+AXIS2_EXTERN axis2_status_t AXIS2_CALL
+axutil_stream_set_peek(
+ axutil_stream_t *stream,
+ const axutil_env_t *env,
+ AXUTIL_STREAM_PEEK func)
+{
+ stream->peek = func;
+ return AXIS2_SUCCESS;
+}
+
AXIS2_EXTERN int AXIS2_CALL
axutil_stream_read(
axutil_stream_t *stream,
@@ -717,3 +728,14 @@ axutil_stream_skip(
{
return stream->skip(stream, env, count);
}
+
+AXIS2_EXTERN int AXIS2_CALL
+axutil_stream_peek(
+ axutil_stream_t *stream,
+ const axutil_env_t *env,
+ void *buffer,
+ int count)
+{
+ return stream->peek(stream, env, buffer, count);
+}
+