MCPcopy Create free account
hub / github.com/apache/httpd / h2_util_bucket_print

Function h2_util_bucket_print

modules/http2/h2_util.c:1267–1288  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1265}
1266
1267apr_size_t h2_util_bucket_print(char *buffer, apr_size_t bmax,
1268 apr_bucket *b, const char *sep)
1269{
1270 apr_size_t off = 0;
1271 if (sep && *sep) {
1272 off += apr_snprintf(buffer+off, bmax-off, "%s", sep);
1273 }
1274
1275 if (bmax <= off) {
1276 return off;
1277 }
1278 else if (APR_BUCKET_IS_METADATA(b)) {
1279 off += apr_snprintf(buffer+off, bmax-off, "%s", b->type->name);
1280 }
1281 else if (bmax > off) {
1282 off += apr_snprintf(buffer+off, bmax-off, "%s[%ld]",
1283 b->type->name,
1284 (b->length == ((apr_size_t)-1)?
1285 -1 : (long)b->length));
1286 }
1287 return off;
1288}
1289
1290apr_size_t h2_util_bb_print(char *buffer, apr_size_t bmax,
1291 const char *tag, const char *sep,

Callers 1

h2_util_bb_printFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected