MCPcopy Create free account
hub / github.com/OpenSIPS/opensips / print_content_length

Function print_content_length

modules/tm/t_msgbuilder.c:578–592  ·  view source on GitHub ↗

* Convert length of body into asciiz */

Source from the content-addressed store, hash-verified

576 * Convert length of body into asciiz
577 */
578static inline int print_content_length(str* dest, str* body)
579{
580 static char content_length[INT2STR_MAX_LEN];
581 int len;
582
583 /* Print Content-Length */
584 if (body && body->len) {
585 dest->s = int2bstr(body->len, content_length, &len);
586 dest->len = len;
587 } else {
588 dest->s = "0";
589 dest->len = 1;
590 }
591 return 0;
592}
593
594
595/*

Callers 1

build_uac_reqFunction · 0.85

Calls 1

int2bstrFunction · 0.85

Tested by

no test coverage detected