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

Function mc_parse_first_line

modules/compression/compression.c:505–523  ·  view source on GitHub ↗

* Function that jumps over the first row of the message * with the received buffer and saves a pointer in the first * arg to the first row along with the length */

Source from the content-addressed store, hash-verified

503 * arg to the first row along with the length
504 */
505static int mc_parse_first_line(str* msg_start, char** buffer)
506{
507 char* buf = *buffer;
508 int len=0;
509
510 msg_start->s = buf;
511 msg_start->len = 0;
512
513 /* Jump over initial row of the message */
514 do {
515 len++;
516 } while (*(buf+len) != '\n');
517 len++;
518
519 msg_start->len = len;
520 *buffer = buf+len;
521
522 return 0;
523}
524
525/*
526 *Function that checks if header is in whitelist

Callers 2

mc_compact_cbFunction · 0.85
mc_compress_cbFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected