00001 /* 00002 * Copyright 2015 Didier Barvaux 00003 * 00004 * This library is free software; you can redistribute it and/or 00005 * modify it under the terms of the GNU Lesser General Public 00006 * License as published by the Free Software Foundation; either 00007 * version 2.1 of the License, or (at your option) any later version. 00008 * 00009 * This library is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00012 * Lesser General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU Lesser General Public 00015 * License along with this library; if not, write to the Free Software 00016 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 00017 */ 00018 00019 /** 00020 * @file /comp/schemes/tcp_sack.h 00021 * @brief Handle encoding of TCP Selective ACKnowledgement (SACK) option 00022 * @author Didier Barvaux <didier@barvaux.org> 00023 */ 00024 00025 #ifndef ROHC_COMP_SCHEMES_TCP_SACK_H 00026 #define ROHC_COMP_SCHEMES_TCP_SACK_H 00027 00028 #include "rohc_comp_internals.h" 00029 #include "protocols/tcp.h" /* for sack_block_t */ 00030 00031 #include <stddef.h> 00032 #include <stdint.h> 00033 00034 int c_tcp_opt_sack_code(const struct rohc_comp_ctxt *const context, 00035 const uint32_t ack_value, 00036 const sack_block_t *const sack_blocks, 00037 const uint8_t length, 00038 const bool is_unchanged, 00039 uint8_t *const rohc_data, 00040 const size_t rohc_max_len) 00041 __attribute__((warn_unused_result, nonnull(1, 3, 6))); 00042 00043 #endif /* ROHC_COMP_SCHEMES_TCP_SACK_H */ 00044
1.6.1