Lines Matching defs:bufs
75 nghttp2_bufs bufs;
85 frame_pack_bufs_init(&bufs);
99 rv = nghttp2_frame_pack_headers(&bufs, &frame, &deflater);
101 nghttp2_bufs_rewind(&bufs);
104 CU_ASSERT(nghttp2_bufs_len(&bufs) > 0);
105 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
107 check_frame_header(nghttp2_bufs_len(&bufs) - NGHTTP2_FRAME_HDLEN,
114 hdblocklen = nghttp2_bufs_len(&bufs) - NGHTTP2_FRAME_HDLEN;
116 inflate_hd(&inflater, &out, &bufs, NGHTTP2_FRAME_HDLEN, mem));
124 nghttp2_bufs_reset(&bufs);
131 rv = nghttp2_frame_pack_headers(&bufs, &frame, &deflater);
134 CU_ASSERT(nghttp2_bufs_len(&bufs) > 0);
135 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
137 check_frame_header(nghttp2_bufs_len(&bufs) - NGHTTP2_FRAME_HDLEN,
147 hdblocklen = nghttp2_bufs_len(&bufs) - NGHTTP2_FRAME_HDLEN -
150 inflate_hd(&inflater, &out, &bufs,
160 nghttp2_bufs_reset(&bufs);
162 nghttp2_bufs_free(&bufs);
171 nghttp2_bufs bufs;
181 frame_pack_bufs_init(&bufs);
198 rv = nghttp2_frame_pack_headers(&bufs, &frame, &deflater);
202 nghttp2_bufs_free(&bufs);
211 nghttp2_bufs bufs;
214 frame_pack_bufs_init(&bufs);
220 nghttp2_frame_pack_priority(&bufs, &frame);
222 CU_ASSERT(NGHTTP2_FRAME_HDLEN + 5 == nghttp2_bufs_len(&bufs));
223 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
232 nghttp2_bufs_reset(&bufs);
234 nghttp2_bufs_free(&bufs);
240 nghttp2_bufs bufs;
242 frame_pack_bufs_init(&bufs);
245 nghttp2_frame_pack_rst_stream(&bufs, &frame);
247 CU_ASSERT(NGHTTP2_FRAME_HDLEN + 4 == nghttp2_bufs_len(&bufs));
248 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
254 nghttp2_bufs_reset(&bufs);
258 nghttp2_frame_pack_rst_stream(&bufs, &frame);
260 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
271 nghttp2_bufs_free(&bufs);
276 nghttp2_bufs bufs;
285 frame_pack_bufs_init(&bufs);
289 rv = nghttp2_frame_pack_settings(&bufs, &frame);
293 nghttp2_bufs_len(&bufs));
295 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
304 nghttp2_bufs_free(&bufs);
313 nghttp2_bufs bufs;
322 frame_pack_bufs_init(&bufs);
332 rv = nghttp2_frame_pack_push_promise(&bufs, &frame, &deflater);
335 CU_ASSERT(nghttp2_bufs_len(&bufs) > 0);
336 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
338 check_frame_header(nghttp2_bufs_len(&bufs) - NGHTTP2_FRAME_HDLEN,
343 hdblocklen = nghttp2_bufs_len(&bufs) - NGHTTP2_FRAME_HDLEN - 4;
345 inflate_hd(&inflater, &out, &bufs, NGHTTP2_FRAME_HDLEN + 4, mem));
352 nghttp2_bufs_free(&bufs);
361 nghttp2_bufs bufs;
364 frame_pack_bufs_init(&bufs);
367 nghttp2_frame_pack_ping(&bufs, &frame);
369 CU_ASSERT(NGHTTP2_FRAME_HDLEN + 8 == nghttp2_bufs_len(&bufs));
370 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
375 nghttp2_bufs_free(&bufs);
382 nghttp2_bufs bufs;
389 frame_pack_bufs_init(&bufs);
395 rv = nghttp2_frame_pack_goaway(&bufs, &frame);
399 nghttp2_bufs_len(&bufs));
400 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
409 nghttp2_bufs_reset(&bufs);
414 rv = nghttp2_frame_pack_goaway(&bufs, &frame);
417 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
425 nghttp2_bufs_free(&bufs);
430 nghttp2_bufs bufs;
432 frame_pack_bufs_init(&bufs);
435 nghttp2_frame_pack_window_update(&bufs, &frame);
437 CU_ASSERT(NGHTTP2_FRAME_HDLEN + 4 == nghttp2_bufs_len(&bufs));
438 CU_ASSERT(0 == unpack_framebuf((nghttp2_frame *)&oframe, &bufs));
443 nghttp2_bufs_free(&bufs);
451 nghttp2_bufs bufs;
462 frame_pack_bufs_init(&bufs);
479 nghttp2_frame_pack_altsvc(&bufs, &frame);
481 CU_ASSERT(NGHTTP2_FRAME_HDLEN + payloadlen == nghttp2_bufs_len(&bufs));
483 rv = unpack_framebuf((nghttp2_frame *)&oframe, &bufs);
498 nghttp2_bufs_free(&bufs);
504 nghttp2_bufs bufs;
528 frame_pack_bufs_init(&bufs);
537 rv = nghttp2_frame_pack_origin(&bufs, &frame);
540 CU_ASSERT(NGHTTP2_FRAME_HDLEN + payloadlen == nghttp2_bufs_len(&bufs));
542 rv = unpack_framebuf((nghttp2_frame *)&oframe, &bufs);
558 buf = &bufs.head->buf;
562 rv = unpack_framebuf((nghttp2_frame *)&oframe, &bufs);
566 nghttp2_bufs_reset(&bufs);
574 rv = nghttp2_frame_pack_origin(&bufs, &frame);
577 CU_ASSERT(NGHTTP2_FRAME_HDLEN == nghttp2_bufs_len(&bufs));
579 rv = unpack_framebuf((nghttp2_frame *)&oframe, &bufs);
590 nghttp2_bufs_free(&bufs);
596 nghttp2_bufs bufs;
601 frame_pack_bufs_init(&bufs);
611 nghttp2_frame_pack_priority_update(&bufs, &frame);
613 CU_ASSERT(NGHTTP2_FRAME_HDLEN + payloadlen == nghttp2_bufs_len(&bufs));
615 rv = unpack_framebuf((nghttp2_frame *)&oframe, &bufs);
626 nghttp2_bufs_free(&bufs);