From 75bdfbf256bf1a38f33423e841ce42370553f310 Mon Sep 17 00:00:00 2001 From: Tatsuhiro Tsujikawa Date: Thu, 23 Feb 2012 23:22:58 +0900 Subject: [PATCH] Made data_prd argument const. --- lib/includes/spdylay/spdylay.h | 6 +++--- lib/spdylay_frame.c | 3 ++- lib/spdylay_frame.h | 3 ++- lib/spdylay_submit.c | 7 ++++--- 4 files changed, 11 insertions(+), 8 deletions(-) diff --git a/lib/includes/spdylay/spdylay.h b/lib/includes/spdylay/spdylay.h index 078f7b1..7ddc8ae 100644 --- a/lib/includes/spdylay/spdylay.h +++ b/lib/includes/spdylay/spdylay.h @@ -483,7 +483,7 @@ void* spdylay_session_get_stream_user_data(spdylay_session *session, */ int spdylay_submit_request(spdylay_session *session, uint8_t pri, const char **nv, - spdylay_data_provider *data_prd, + const spdylay_data_provider *data_prd, void *stream_user_data); /* @@ -509,7 +509,7 @@ int spdylay_submit_request(spdylay_session *session, uint8_t pri, */ int spdylay_submit_response(spdylay_session *session, int32_t stream_id, const char **nv, - spdylay_data_provider *data_prd); + const spdylay_data_provider *data_prd); /* * Submits SYN_STREAM frame. The |flags| is bitwise OR of the @@ -554,7 +554,7 @@ int spdylay_submit_syn_stream(spdylay_session *session, uint8_t flags, * Out of memory. */ int spdylay_submit_data(spdylay_session *session, int32_t stream_id, - uint8_t flags, spdylay_data_provider *data_prd); + uint8_t flags, const spdylay_data_provider *data_prd); /* * Submits RST_STREAM frame to cancel/reject stream |stream_id| with diff --git a/lib/spdylay_frame.c b/lib/spdylay_frame.c index 2f78715..23d7d2a 100644 --- a/lib/spdylay_frame.c +++ b/lib/spdylay_frame.c @@ -478,7 +478,8 @@ void spdylay_frame_settings_free(spdylay_settings *frame) } void spdylay_frame_data_init(spdylay_data *frame, int32_t stream_id, - uint8_t flags, spdylay_data_provider *data_prd) + uint8_t flags, + const spdylay_data_provider *data_prd) { memset(frame, 0, sizeof(spdylay_data)); frame->stream_id = stream_id; diff --git a/lib/spdylay_frame.h b/lib/spdylay_frame.h index 261455b..7acb312 100644 --- a/lib/spdylay_frame.h +++ b/lib/spdylay_frame.h @@ -429,7 +429,8 @@ void spdylay_frame_settings_init(spdylay_settings *frame, uint8_t flags, void spdylay_frame_settings_free(spdylay_settings *frame); void spdylay_frame_data_init(spdylay_data *frame, int32_t stream_id, - uint8_t flags, spdylay_data_provider *data_prd); + uint8_t flags, + const spdylay_data_provider *data_prd); void spdylay_frame_data_free(spdylay_data *frame); diff --git a/lib/spdylay_submit.c b/lib/spdylay_submit.c index 91fa386..920bf3f 100644 --- a/lib/spdylay_submit.c +++ b/lib/spdylay_submit.c @@ -124,7 +124,8 @@ int spdylay_submit_goaway(spdylay_session *session) } int spdylay_submit_request(spdylay_session *session, uint8_t pri, - const char **nv, spdylay_data_provider *data_prd, + const char **nv, + const spdylay_data_provider *data_prd, void *stream_user_data) { int flags; @@ -138,7 +139,7 @@ int spdylay_submit_request(spdylay_session *session, uint8_t pri, int spdylay_submit_response(spdylay_session *session, int32_t stream_id, const char **nv, - spdylay_data_provider *data_prd) + const spdylay_data_provider *data_prd) { int r; spdylay_frame *frame; @@ -182,7 +183,7 @@ int spdylay_submit_response(spdylay_session *session, int spdylay_submit_data(spdylay_session *session, int32_t stream_id, uint8_t flags, - spdylay_data_provider *data_prd) + const spdylay_data_provider *data_prd) { int r; spdylay_frame *frame;