diff --git a/python/cnghttp2.pxd b/python/cnghttp2.pxd index 9fefc832..9252d4c8 100644 --- a/python/cnghttp2.pxd +++ b/python/cnghttp2.pxd @@ -53,11 +53,16 @@ cdef extern from 'nghttp2/nghttp2.h': NGHTTP2_PUSH_PROMISE NGHTTP2_GOAWAY + ctypedef enum nghttp2_nv_flag: + NGHTTP2_NV_FLAG_NONE + NGHTTP2_NV_FLAG_NO_INDEX + ctypedef struct nghttp2_nv: uint8_t *name uint8_t *value uint16_t namelen uint16_t valuelen + uint8_t flags ctypedef enum nghttp2_settings_id: SETTINGS_HEADER_TABLE_SIZE @@ -146,6 +151,7 @@ cdef extern from 'nghttp2/nghttp2.h': const nghttp2_frame *frame, const uint8_t *name, size_t namelen, const uint8_t *value, size_t valuelen, + uint8_t flags, void *user_data) ctypedef int (*nghttp2_on_frame_send_callback)\ diff --git a/python/nghttp2.pyx b/python/nghttp2.pyx index 9741619c..441e84b1 100644 --- a/python/nghttp2.pyx +++ b/python/nghttp2.pyx @@ -112,6 +112,7 @@ cdef class HDDeflater: nvap[0].namelen = len(k) nvap[0].value = v nvap[0].valuelen = len(v) + nvap[0].flags = cnghttp2.NGHTTP2_NV_FLAG_NONE nvap += 1 cdef cnghttp2.nghttp2_bufs bufs @@ -294,6 +295,7 @@ cdef size_t _make_nva(cnghttp2.nghttp2_nv **nva_ptr, headers): nva[i].namelen = len(k) nva[i].value = v nva[i].valuelen = len(v) + nva[i].flags = cnghttp2.NGHTTP2_NV_FLAG_NONE nva_ptr[0] = nva @@ -303,6 +305,7 @@ cdef int server_on_header(cnghttp2.nghttp2_session *session, const cnghttp2.nghttp2_frame *frame, const uint8_t *name, size_t namelen, const uint8_t *value, size_t valuelen, + uint8_t flags, void *user_data): cdef http2 = <_HTTP2SessionCore>user_data