Adjust benchmark directory,enable HTTP test,rename variables,format codes

This commit is contained in:
lijia
2024-08-16 14:58:19 +08:00
parent cd2a2360fe
commit 3cdfabb683
153 changed files with 1064 additions and 4415 deletions

View File

@@ -1,4 +1,4 @@
#pragma once
#pragma once
#include <stdlib.h>
#include <stdio.h>
@@ -29,7 +29,8 @@ int httpd_url_is_encoded(const char *url, size_t len);
* Logger
******************************************************************************/
enum http_decoder_log_level {
enum http_decoder_log_level
{
DEBUG = 0x11,
WARN = 0x12,
INFO = 0x13,
@@ -61,20 +62,19 @@ enum http_decoder_log_level {
}
#endif
#include <netinet/in.h>
struct httpd_session_addr
{
uint8_t ipver; /* 4 or 6 */
uint16_t sport; /* network order */
uint16_t dport; /* network order */
union
{
uint8_t ipver; /* 4 or 6 */
uint16_t sport; /* network order */
uint16_t dport; /* network order */
union
{
uint32_t saddr4;
uint32_t daddr4;
struct in6_addr saddr6;
struct in6_addr saddr6;
struct in6_addr daddr6;
};
};
};
void httpd_session_get_addr(const struct session *sess, struct httpd_session_addr *addr);