This repository has been archived on 2025-09-14. You can view files and clone it, but cannot push or open issues or pull requests.
Files
mesa-framework-mesa-jump-layer/inc/MESA_jump_layer.h
2021-09-14 17:33:59 +08:00

30 lines
737 B
C

#ifndef __MESA_JUMP_LAYER_H_
#define __MESA_JUMP_LAYER_H_ 1
#endif
#ifdef __cplusplus
extern "C" {
#endif
#include "stream.h"
#include <netinet/ip.h>
#include <netinet/ip6.h>
const char *MESA_jump_layer_get_last_error(void);
/*
The raw_layer_type and expect_layer_type refer to sapp_base.h->enum addr_type_t
*/
const void *MESA_jump_layer(const void *raw_data, int raw_layer_type, int expect_layer_type);
const void *MESA_jump_layer_greedy(const void *raw_data, int raw_layer_type, int expect_layer_type);
const char *MESA_jump_layer_ipv4_ntop(const struct ip *ip4_hdr, char *out_buf, int buf_len );
const char *MESA_jump_layer_ipv6_ntop(const struct ip6_hdr *ip6_hdr, char *out_buf, int buf_len);
#ifdef __cplusplus
}
#endif