tcp_ts.c File Reference

Handle encoding of TCP TimeStamp (TS) option. More...

#include "tcp_ts.h"
#include <string.h>
Include dependency graph for comp/schemes/tcp_ts.c:

Functions

bool c_tcp_ts_lsb_code (const struct rohc_comp_ctxt *const context, const uint32_t timestamp, const size_t nr_bits_minus_1, const size_t nr_bits_0x40000, const size_t nr_bits_0x4000000, uint8_t *const rohc_data, const size_t rohc_max_len, size_t *const rohc_len)
 Compress the TimeStamp option value.

Detailed Description

Handle encoding of TCP TimeStamp (TS) option.

Author:
Didier Barvaux <didier@barvaux.org>

Function Documentation

bool c_tcp_ts_lsb_code ( const struct rohc_comp_ctxt *const   context,
const uint32_t  timestamp,
const size_t  nr_bits_minus_1,
const size_t  nr_bits_0x40000,
const size_t  nr_bits_0x4000000,
uint8_t *const   rohc_data,
const size_t  rohc_max_len,
size_t *const   rohc_len 
)

Compress the TimeStamp option value.

See RFC4996 page 65

Parameters:
context The compression context
timestamp The timestamp value to compress
nr_bits_minus_1 The minimal number of required bits for p = -1
nr_bits_0x40000 The minimal number of required bits for p = 0x40000
nr_bits_0x4000000 The minimal number of required bits for p = 0x4000000
[out] rohc_data The ROHC packet being built
rohc_max_len The max remaining length in the ROHC buffer
[out] rohc_len The length appended in the ROHC buffer
Returns:
true if compression was successful, false otherwise

Generated on 4 Jul 2018 for ROHC compression/decompression library by  doxygen 1.6.1