diff --git a/lib/includes/nghttp2/nghttp2.h b/lib/includes/nghttp2/nghttp2.h index 6547ad93..e8ccd159 100644 --- a/lib/includes/nghttp2/nghttp2.h +++ b/lib/includes/nghttp2/nghttp2.h @@ -2230,7 +2230,7 @@ int nghttp2_submit_ping(nghttp2_session *session, uint8_t flags, */ int nghttp2_submit_goaway(nghttp2_session *session, uint8_t flags, nghttp2_error_code error_code, - uint8_t *opaque_data, size_t opaque_data_len); + const uint8_t *opaque_data, size_t opaque_data_len); /** * @function diff --git a/lib/nghttp2_session.c b/lib/nghttp2_session.c index 6f81466c..4eb2beb0 100644 --- a/lib/nghttp2_session.c +++ b/lib/nghttp2_session.c @@ -4650,7 +4650,8 @@ int nghttp2_session_add_ping(nghttp2_session *session, uint8_t flags, int nghttp2_session_add_goaway(nghttp2_session *session, int32_t last_stream_id, nghttp2_error_code error_code, - uint8_t *opaque_data, size_t opaque_data_len) + const uint8_t *opaque_data, + size_t opaque_data_len) { int rv; nghttp2_frame *frame; diff --git a/lib/nghttp2_session.h b/lib/nghttp2_session.h index 745a0d71..3d5dd1b3 100644 --- a/lib/nghttp2_session.h +++ b/lib/nghttp2_session.h @@ -274,7 +274,8 @@ int nghttp2_session_add_ping(nghttp2_session *session, uint8_t flags, int nghttp2_session_add_goaway(nghttp2_session *session, int32_t last_stream_id, nghttp2_error_code error_code, - uint8_t *opaque_data, size_t opaque_data_len); + const uint8_t *opaque_data, + size_t opaque_data_len); /* * Adds WINDOW_UPDATE frame with stream ID |stream_id| and diff --git a/lib/nghttp2_submit.c b/lib/nghttp2_submit.c index 7d50f21e..9836fa5f 100644 --- a/lib/nghttp2_submit.c +++ b/lib/nghttp2_submit.c @@ -167,7 +167,7 @@ int nghttp2_submit_rst_stream(nghttp2_session *session, uint8_t flags, int nghttp2_submit_goaway(nghttp2_session *session, uint8_t flags, nghttp2_error_code error_code, - uint8_t *opaque_data, size_t opaque_data_len) + const uint8_t *opaque_data, size_t opaque_data_len) { return nghttp2_session_add_goaway(session, session->last_stream_id, error_code, opaque_data, opaque_data_len);