#include <stdint.h>
#include <sys/types.h>
-#include "nghttp2ver.h"
+#include <nghttp2ver.h>
/**
* @macro
NGHTTP2_ERR_CALLBACK_FAILURE = -902
} nghttp2_error;
-typedef enum {
- NGHTTP2_MSG_MORE
-} nghttp2_io_flag;
-
/**
* @enum
*
*/
NGHTTP2_SETTINGS_INITIAL_WINDOW_SIZE = 0x04
} nghttp2_settings_id;
+/* Note: If we add SETTINGS, update the capacity of
+ NGHTTP2_INBOUND_NUM_IV as well */
/**
* @macro
static ssize_t bufs_avail(nghttp2_bufs *bufs)
{
- return (ssize_t)(nghttp2_buf_avail(&bufs->cur->buf) +
- (bufs->chunk_length - bufs->offset) * (bufs->max_chunk - bufs->chunk_used));
+ return (ssize_t)nghttp2_buf_avail(&bufs->cur->buf) +
+ (bufs->chunk_length - bufs->offset) * (bufs->max_chunk - bufs->chunk_used);
}
static int bufs_alloc_chain(nghttp2_bufs *bufs)
return chain && nghttp2_buf_len(&chain->buf);
}
+
*/
ssize_t nghttp2_bufs_len(nghttp2_bufs *bufs);
-#endif /* NGHTTP2_BUF_H */
\ No newline at end of file
+#endif /* NGHTTP2_BUF_H */
return h;
}
-typedef struct {
- nghttp2_nv *nva;
- size_t nvacap;
- size_t nvlen;
-} nghttp2_nva_out;
-
int nghttp2_hd_entry_init(nghttp2_hd_entry *ent, uint8_t flags,
uint8_t *name, size_t namelen,
uint8_t *value, size_t valuelen)
rv = nghttp2_hd_deflate_init2(deflater, deflate_hd_table_bufsize_max);
if(rv != 0) {
+ free(deflater);
+
return rv;
}
goto fail;
}
- return (ssize_t)(in - first);
+ return in - first;
fail:
DEBUGF(fprintf(stderr, "inflatehd: error return %zd\n", rv));
rv = nghttp2_hd_inflate_init(inflater);
if(rv != 0) {
+ free(inflater);
+
return rv;
}
* @macro
* Version number of the nghttp2 library release
*/
-#define NGHTTP2_VERSION "0.4.2-DEV"
+#define NGHTTP2_VERSION "0.5.0"
/**
* @macro
* release. This is a 24 bit number with 8 bits for major number, 8 bits
* for minor and 8 bits for patch. Version 1.2.3 becomes 0x010203.
*/
-#define NGHTTP2_VERSION_NUM 0x000402
+#define NGHTTP2_VERSION_NUM 0x000500
#endif /* NGHTTP2VER_H */