Update Android support.

This commit is contained in:
bossiel 2010-02-21 19:40:59 +00:00
parent 519f921fa9
commit 788da34e1d
166 changed files with 510 additions and 252 deletions

View File

@ -47,6 +47,9 @@ THTTP_BEGIN_DECLS
#define THTTP_HEADER(self) ((thttp_header_t*)(self))
#define THTTP_HEADER_PARAMS(self) (THTTP_HEADER(self)->params)
// FD
struct thttp_header_s;
typedef int (*thttp_header_value_tostring)(const struct thttp_header_s* header, tsk_buffer_t* output);
/**

View File

@ -164,43 +164,43 @@ thttp_message_t;
typedef thttp_message_t thttp_request_t; /**< HTTP request message. */
typedef thttp_message_t thttp_response_t; /**< HTTP response message. */
//
TINYHTTP_API int thttp_message_add_header(thttp_message_t *self, const thttp_header_t *hdr);
TINYHTTP_API int thttp_message_add_headers(thttp_message_t *self, const thttp_headers_L_t *headers);
#if !defined(_MSC_VER) || defined(__GNUC__)
static void THTTP_MESSAGE_ADD_HEADER(thttp_message_t *self, ...)
{
va_list ap;
thttp_header_t *header;
const tsk_object_def_t *objdef;
va_start(ap, self);
objdef = va_arg(ap, const tsk_object_def_t*);
header = tsk_object_new2(objdef, &ap);
va_end(ap);
thttp_message_add_header(self, header);
tsk_object_unref(header);
}
#else
#define THTTP_MESSAGE_ADD_HEADER(self, objdef, ...) \
{ \
thttp_header_t *header = tsk_object_new(objdef, __VA_ARGS__); \
thttp_message_add_header(self, header); \
tsk_object_unref(header); \
}
#endif
TINYHTTP_API const thttp_header_t *thttp_message_get_headerAt(const thttp_message_t *self, thttp_header_type_t type, size_t index);
TINYHTTP_API const thttp_header_t *thttp_message_get_header(const thttp_message_t *self, thttp_header_type_t type);
//TINYHTTP_API int thttp_message_add_headers(thttp_message_t *self, const thttp_headers_L_t *headers);
//
//#if !defined(_MSC_VER) || defined(__GNUC__)
//static void THTTP_MESSAGE_ADD_HEADER(thttp_message_t *self, ...)
// {
// va_list ap;
// thttp_header_t *header;
// const tsk_object_def_t *objdef;
//
// va_start(ap, self);
// objdef = va_arg(ap, const tsk_object_def_t*);
// header = tsk_object_new2(objdef, &ap);
// va_end(ap);
//
// thttp_message_add_header(self, header);
// tsk_object_unref(header);
// }
//#else
//#define THTTP_MESSAGE_ADD_HEADER(self, objdef, ...) \
// { \
// thttp_header_t *header = tsk_object_new(objdef, __VA_ARGS__); \
// thttp_message_add_header(self, header); \
// tsk_object_unref(header); \
// }
//#endif
//
//TINYHTTP_API const thttp_header_t *thttp_message_get_headerAt(const thttp_message_t *self, thttp_header_type_t type, size_t index);
//TINYHTTP_API const thttp_header_t *thttp_message_get_header(const thttp_message_t *self, thttp_header_type_t type);
//
TINYHTTP_API uint32_t thttp_message_getContent_length(const thttp_message_t *message);
TINYHTTP_API int thttp_message_tostring(const thttp_message_t *self, tsk_buffer_t *output);
TINYHTTP_API thttp_request_t *thttp_request_new(const char* method, const thttp_url_t *request_url, const thttp_url_t *from, const thttp_url_t *to, const char *call_id, int32_t cseq);
TINYHTTP_API thttp_response_t *thttp_response_new(short status_code, const char* reason_phrase, const thttp_request_t *request);
//
//TINYHTTP_API int thttp_message_tostring(const thttp_message_t *self, tsk_buffer_t *output);
//
//TINYHTTP_API thttp_request_t *thttp_request_new(const char* method, const thttp_url_t *request_url, const thttp_url_t *from, const thttp_url_t *to, const char *call_id, int32_t cseq);
//TINYHTTP_API thttp_response_t *thttp_response_new(short status_code, const char* reason_phrase, const thttp_request_t *request);
TINYHTTP_GEXTERN const void *thttp_message_def_t;

View File

@ -10,7 +10,7 @@ all: $(APP)
OBJS = \
thttp.o\
thttp_message.o\
thttp_utl.o
thttp_url.o
###################
## auth
###################
@ -18,6 +18,16 @@ OBJS += auth/thttp_auth.o
###################
## headers
###################
OBJS += headers/thttp_header.o\
headers/thttp_header_Authorization.o\
headers/thttp_header_Proxy_Authenticate.o\
headers/thttp_header_WWW_Authenticate.o
###################
## parsers
###################
OBJS += parsers/thttp_parser_header.o\
parsers/thttp_parser_message.o\
parsers/thttp_parser_url.o
$(APP): $(OBJS)
$(CPP) $(LDFLAGS) -o $@ $^

View File

@ -0,0 +1,91 @@
/*
* Copyright (C) 2009 Mamadou Diop.
*
* Contact: Mamadou Diop <diopmamadou@yahoo.fr>
*
* This file is part of Open Source Doubango Framework.
*
* DOUBANGO is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* DOUBANGO is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with DOUBANGO.
*
*/
/**@file thttp_message.c
* @brief Represents a HTTP message. A HTTP message is either a request from a client to a server, or a
* response from a server to a client.
*
* @author Mamadou Diop <diopmamadou(at)yahoo.fr>
*
* @date Created: Sat Nov 8 16:54:58 2009 mdiop
*/
#include "tinyHTTP/thttp_message.h"
int thttp_message_add_header(thttp_message_t *self, const thttp_header_t *hdr)
{
return -1;
}
uint32_t thttp_message_getContent_length(const thttp_message_t *message)
{
return 0;
}
//=================================================================================================
// THTTP mesage object definition
//
static void* thttp_message_create(void * self, va_list * app)
{
thttp_message_t *message = self;
if(message)
{
}
return self;
}
static void* thttp_message_destroy(void * self)
{
thttp_message_t *message = self;
if(message)
{
}
return self;
}
static int thttp_message_cmp(const void *obj1, const void *obj2)
{
return -1;
}
static const tsk_object_def_t thttp_message_def_s =
{
sizeof(thttp_message_t),
thttp_message_create,
thttp_message_destroy,
thttp_message_cmp,
};
const void *thttp_message_def_t = &thttp_message_def_s;

View File

@ -51,6 +51,7 @@
RuntimeLibrary="3"
UsePrecompiledHeader="0"
WarningLevel="3"
WarnAsError="true"
DebugInformationFormat="4"
CompileAs="1"
/>
@ -166,7 +167,7 @@
/>
<DeploymentTool
ForceDirty="-1"
RemoteDirectory=""
RemoteDirectory="%CSIDL_PROGRAM_FILES%\test"
RegisterOutput="0"
AdditionalFiles=""
/>

View File

@ -28,9 +28,6 @@
*
* @brief poll() method implementation for multiplexing network sockets.
*
* @author Mamadou Diop <diopmamadou(at)yahoo.fr>
* @date Created: Sat Nov 8 16:54:58 2009 mdiop /
*
* @param fds An array of pollfd structures.
* @param nfds The number of file descriptors set in fds[ ].
* @param timeout How long poll() should wait for an event to occur (in milliseconds).

View File

@ -162,7 +162,11 @@ static void* tnet_socket_create(void * self, va_list * app)
hints.ai_family = TNET_SOCKET_TYPE_IS_IPV6(sock->type) ? AF_INET6 : AF_INET;
hints.ai_socktype = TNET_SOCKET_TYPE_IS_STREAM(sock->type) ? SOCK_STREAM : SOCK_DGRAM;
hints.ai_protocol = TNET_SOCKET_TYPE_IS_STREAM(sock->type) ? IPPROTO_TCP : IPPROTO_UDP;
hints.ai_flags = AI_PASSIVE /*| AI_ADDRCONFIG*/; /* Bind to the local machine. */
hints.ai_flags = AI_PASSIVE
#if !TNET_UNDER_WINDOWS
| AI_ADDRCONFIG
#endif
;
/* Performs getaddrinfo */
if((status = tnet_getaddrinfo(local_hostname, port, &hints, &result)))
@ -177,32 +181,23 @@ static void* tnet_socket_create(void * self, va_list * app)
//if(ptr->ai_family == hints.ai_family && ptr->ai_socktype == hints.ai_socktype && ptr->ai_protocol == hints.ai_protocol)
{
sock->fd = socket(ptr->ai_family, ptr->ai_socktype, ptr->ai_protocol);
/* Get local IP string. */
if((status = tnet_getnameinfo(ptr->ai_addr, ptr->ai_addrlen, sock->ip, sizeof(sock->ip), 0, 0, NI_NUMERICHOST)))
{
TNET_PRINT_LAST_ERROR("getnameinfo have failed");
tnet_socket_close(sock);
continue;
}
else
{
/* Bind the socket */
if((status = bind(sock->fd, ptr->ai_addr, ptr->ai_addrlen)))
{
TNET_PRINT_LAST_ERROR("bind have failed.");
tnet_socket_close(sock);
continue;
}
else
/* Get local IP string. */
if(status = tnet_get_ip_n_port(sock->fd , &sock->ip, &sock->port)) /* % */
//if((status = tnet_getnameinfo(ptr->ai_addr, ptr->ai_addrlen, sock->ip, sizeof(sock->ip), 0, 0, NI_NUMERICHOST)))
{
if(sock->port == TNET_SOCKET_PORT_ANY && (status = tnet_get_port(sock->fd, &(sock->port))))
{
TNET_PRINT_LAST_ERROR("Failed to retrieve IP and Port.");
TNET_PRINT_LAST_ERROR("Failed to get local IP and port.");
tnet_socket_close(sock);
continue;
}
else break;
}
}
}
}

View File

@ -54,6 +54,7 @@ typedef struct transport_context_s
size_t count;
short events;
tnet_fd_t pipeW;
tnet_fd_t pipeR;
tnet_pollfd_t ufds[TNET_MAX_FDS];
transport_socket_t* sockets[TNET_MAX_FDS];
}
@ -108,7 +109,8 @@ int tnet_transport_add_socket(const tnet_transport_handle_t *handle, tnet_fd_t f
transport_socket_add(fd, context);
// signal
return (write(context->pipeW, &c, 1) > 0);
ret = write(context->pipeW, &c, 1);
return (ret > 0 ? 0 : ret);
}
// ...
@ -357,7 +359,7 @@ void *tnet_transport_mainthread(void *param)
transport_socket_t* active_socket;
context = (transport_context_t*)tsk_calloc(1, sizeof(transport_context_t));
context->events = TNET_SOCKET_TYPE_IS_DGRAM(transport->master->type) ? TNET_POLLIN : TNET_POLLIN | TNET_POLLOUT | TNET_POLLPRI;
context->events = TNET_SOCKET_TYPE_IS_DGRAM(transport->master->type) ? TNET_POLLIN : TNET_POLLIN /*| TNET_POLLOUT*/ | TNET_POLLPRI;
transport->context = context;
/* Start listening */
@ -376,9 +378,12 @@ void *tnet_transport_mainthread(void *param)
TNET_PRINT_LAST_ERROR("Failed to create new pipes.");
goto bail;
}
transport_socket_add(pipes[0], context); // Add pipeR
context->pipeR = pipes[0];
context->pipeW = pipes[1];
transport_socket_add(context->pipeR, context);
/* Add the current transport socket to the context. */
transport_socket_add(transport->master->fd, context);
@ -406,7 +411,9 @@ void *tnet_transport_mainthread(void *param)
*/
for(i=0; i<context->count; i++)
{
if(!context->ufds[i].revents) continue;
if(!context->ufds[i].revents || context->ufds[i].fd == context->pipeR){
continue;
}
/* Get active event and socket */
active_socket = context->sockets[i];
@ -436,7 +443,7 @@ void *tnet_transport_mainthread(void *param)
}
/* Receive the waiting data. */
if(recv(active_socket->fd, buffer, len, 0) < 0)
if((ret = recv(active_socket->fd, buffer, len, 0)) < 0)
{
TSK_FREE(buffer);
//if(tnet_geterrno() == TNET_ERROR_WOULDBLOCK)

View File

@ -70,8 +70,8 @@ void tnet_getlasterror(tnet_error_t *error)
0);
}
#else
//FIXME: use strerror(errno);
sprintf(*error, "Network error (%d).", err);
strerror_r(err, *error, sizeof(*error));
//sprintf(*error, "Network error (%d).", err);
#endif
}
@ -117,8 +117,7 @@ tnet_interfaces_L_t* tnet_get_interfaces()
TSK_DEBUG_ERROR("Error allocating memory needed to call GetAdaptersinfo.");
goto bail;
}
// Make an initial call to GetAdaptersInfo to get
// the necessary size into the ulOutBufLen variable
// Make an initial call to GetAdaptersInfo to get the necessary size into the ulOutBufLen variable
if (GetAdaptersInfo(pAdapterInfo, &ulOutBufLen) == ERROR_BUFFER_OVERFLOW)
{
FREE(pAdapterInfo);
@ -135,7 +134,13 @@ tnet_interfaces_L_t* tnet_get_interfaces()
pAdapter = pAdapterInfo;
while(pAdapter)
{
tnet_interface_t *iface = TNET_INTERFACE_CREATE(pAdapter->Description, pAdapter->Address, pAdapter->AddressLength);
tnet_interface_t *iface;
if(pAdapter->Type == MIB_IF_TYPE_LOOPBACK){
continue;
}
iface = TNET_INTERFACE_CREATE(pAdapter->Description, pAdapter->Address, pAdapter->AddressLength);
iface->index = pAdapter->Index;
tsk_list_push_back_data(ifaces, &(iface));
@ -264,7 +269,7 @@ bail:
return ifaces;
}
tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, unsigned anycast, unsigned multicast, unsigned dnsserver)
tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, unsigned anycast, unsigned multicast, unsigned dnsserver, long if_index)
{
tnet_addresses_L_t *addresses = TSK_LIST_CREATE();
tnet_ip_t ip;
@ -320,12 +325,16 @@ tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, u
pCurrAddresses = pAddresses;
while (pCurrAddresses)
{
if((if_index != -1) && (pCurrAddresses->IfIndex != if_index && pCurrAddresses->Ipv6IfIndex != if_index)){
goto next;
}
/* UNICAST addresses
*/
pUnicast = pCurrAddresses->FirstUnicastAddress;
while(unicast && pUnicast)
{
memset(ip, '\0', sizeof(ip));
//memset(ip, '\0', sizeof(ip));
tnet_get_sockip(pUnicast->Address.lpSockaddr, &ip);
{
tnet_address_t *address = TNET_ADDRESS_CREATE(ip);
@ -342,7 +351,7 @@ tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, u
pAnycast = pCurrAddresses->FirstAnycastAddress;
while(anycast && pAnycast)
{
memset(ip, '\0', sizeof(ip));
//memset(ip, '\0', sizeof(ip));
tnet_get_sockip(pAnycast->Address.lpSockaddr, &ip);
{
tnet_address_t *address = TNET_ADDRESS_CREATE(ip);
@ -359,7 +368,7 @@ tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, u
pMulticast = pCurrAddresses->FirstMulticastAddress;
while(multicast && pMulticast)
{
memset(ip, '\0', sizeof(ip));
//memset(ip, '\0', sizeof(ip));
tnet_get_sockip(pMulticast->Address.lpSockaddr, &ip);
{
tnet_address_t *address = TNET_ADDRESS_CREATE(ip);
@ -376,7 +385,7 @@ tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, u
pDnServer = pCurrAddresses->FirstDnsServerAddress;
while(dnsserver && pDnServer)
{
memset(ip, '\0', sizeof(ip));
//memset(ip, '\0', sizeof(ip));
tnet_get_sockip(pDnServer->Address.lpSockaddr, &ip);
{
tnet_address_t *address = TNET_ADDRESS_CREATE(ip);
@ -387,7 +396,7 @@ tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, u
pDnServer = pDnServer->Next;
}
next:
pCurrAddresses = pCurrAddresses->Next;
}
}
@ -415,6 +424,56 @@ bail:
return addresses;
}
int tnet_getbestsource(const char* destination, tnet_socket_type_t type, tnet_ip_t *source)
{
int ret = -1;
struct sockaddr_storage destAddr;
tnet_addresses_L_t* addresses = 0;
const tsk_list_item_t* item;
#if TNET_UNDER_WINDOWS
DWORD dwBestIfIndex;
#endif
if(!destination || !source){
goto bail;
}
if((ret = tnet_sockaddr_init(destination, 0, type, &destAddr))){
goto bail;
}
#if TNET_UNDER_WINDOWS
if(GetBestInterfaceEx((struct sockaddr*)&destAddr, &dwBestIfIndex) != NO_ERROR){
ret = WSAGetLastError();
TNET_PRINT_LAST_ERROR("GetBestInterfaceEx failed.");
goto bail;
}
#endif
if(!(addresses = tnet_get_addresses(TNET_SOCKET_TYPE_IS_IPV6(type) ? AF_INET6 : AF_INET, 1, 0, 0, 0, dwBestIfIndex))){
ret = -2;
TSK_DEBUG_ERROR("Failed to retrieve addresses.");
goto bail;
}
tsk_list_foreach(item, addresses)
{
const tnet_address_t* address = item->data;
if(address && address->ip){
memset(*source, '\0', sizeof(*source));
memcpy(*source, address->ip, strlen(address->ip) > sizeof(*source) ? sizeof(*source) : strlen(address->ip));
ret = 0;
goto bail; // First is good for us.
}
}
bail:
TSK_OBJECT_SAFE_FREE(addresses);
return ret;
}
/**
* @fn int tnet_getaddrinfo(const char *node, const char *service,
* const struct addrinfo *hints, struct addrinfo **res)
@ -512,6 +571,9 @@ int tnet_get_sockip_n_port(struct sockaddr *addr, tnet_ip_t *ip, tnet_port_t *po
else if(addr->sa_family == AF_INET6)
{
struct sockaddr_in6 *sin6 = (struct sockaddr_in6 *)addr;
#if TNET_UNDER_WINDOWS
int index;
#endif
if(port)
{
*port = ntohs(sin6->sin6_port);
@ -523,6 +585,12 @@ int tnet_get_sockip_n_port(struct sockaddr *addr, tnet_ip_t *ip, tnet_port_t *po
{
return status;
}
#if TNET_UNDER_WINDOWS
if((index = tsk_strindexOf(*ip, strlen(*ip), "%")) > 0){
*(*ip + index) = '\0';
}
#endif
}
}
else
@ -536,7 +604,9 @@ int tnet_get_sockip_n_port(struct sockaddr *addr, tnet_ip_t *ip, tnet_port_t *po
int tnet_get_ip_n_port(tnet_fd_t fd, tnet_ip_t *ip, tnet_port_t *port)
{
if(port){
*port = 0;
}
if(fd > 0)
{

View File

@ -75,21 +75,22 @@ TINYNET_API void tnet_getlasterror(tnet_error_t *error);
TINYNET_API int tnet_geterrno();
TINYNET_API tnet_interfaces_L_t* tnet_get_interfaces();
TINYNET_API tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, unsigned anycast, unsigned multicast, unsigned dnsserver);
#define tnet_get_addresses_all() tnet_get_addresses(AF_UNSPEC, 1, 1, 1, 1)
#define tnet_get_addresses_all_unicast() tnet_get_addresses(AF_UNSPEC, 1, 0, 0, 0)
#define tnet_get_addresses_unicast4() tnet_get_addresses(AF_INET, 1, 0, 0, 0)
#define tnet_get_addresses_unicast6() tnet_get_addresses(AF_INET6, 1, 0, 0, 0)
#define tnet_get_addresses_all_anycast() tnet_get_addresses(AF_UNSPEC, 0, 1, 0, 0)
#define tnet_get_addresses_anycast4() tnet_get_addresses(AF_INET, 0, 1, 0, 0)
#define tnet_get_addresses_anycast6() tnet_get_addresses(AF_INET6, 0, 1, 0, 0)
#define tnet_get_addresses_all_multicast() tnet_get_addresses(AF_UNSPEC, 0, 0, 1, 0)
#define tnet_get_addresses_multicast4() tnet_get_addresses(AF_INET, 0, 0, 1, 0)
#define tnet_get_addresses_multicast6() tnet_get_addresses(AF_INET6, 0, 0, 1, 0)
#define tnet_get_addresses_all_dnsservers() tnet_get_addresses(AF_UNSPEC, 0, 0, 0, 1)
#define tnet_get_addresses_dnsservers4() tnet_get_addresses(AF_INET, 0, 0, 0, 1)
#define tnet_get_addresses_dnsservers6() tnet_get_addresses(AF_INET6, 0, 0, 0, 1)
TINYNET_API tnet_addresses_L_t* tnet_get_addresses(tnet_family_t family, unsigned unicast, unsigned anycast, unsigned multicast, unsigned dnsserver, long if_index);
#define tnet_get_addresses_all() tnet_get_addresses(AF_UNSPEC, 1, 1, 1, 1, -1)
#define tnet_get_addresses_all_unicast() tnet_get_addresses(AF_UNSPEC, 1, 0, 0, 0, -1)
#define tnet_get_addresses_unicast4() tnet_get_addresses(AF_INET, 1, 0, 0, 0, -1)
#define tnet_get_addresses_unicast6() tnet_get_addresses(AF_INET6, 1, 0, 0, 0, -1)
#define tnet_get_addresses_all_anycast() tnet_get_addresses(AF_UNSPEC, 0, 1, 0, 0, -1)
#define tnet_get_addresses_anycast4() tnet_get_addresses(AF_INET, 0, 1, 0, 0, -1)
#define tnet_get_addresses_anycast6() tnet_get_addresses(AF_INET6, 0, 1, 0, 0, -1)
#define tnet_get_addresses_all_multicast() tnet_get_addresses(AF_UNSPEC, 0, 0, 1, 0, -1)
#define tnet_get_addresses_multicast4() tnet_get_addresses(AF_INET, 0, 0, 1, 0, -1)
#define tnet_get_addresses_multicast6() tnet_get_addresses(AF_INET6, 0, 0, 1, 0, -1)
#define tnet_get_addresses_all_dnsservers() tnet_get_addresses(AF_UNSPEC, 0, 0, 0, 1, -1)
#define tnet_get_addresses_dnsservers4() tnet_get_addresses(AF_INET, 0, 0, 0, 1, -1)
#define tnet_get_addresses_dnsservers6() tnet_get_addresses(AF_INET6, 0, 0, 0, 1, -1)
TINYNET_API int tnet_getbestsource(const char* destination, tnet_socket_type_t type, tnet_ip_t *source);
TINYNET_API int tnet_getaddrinfo(const char *node, const char *service, const struct addrinfo *hints, struct addrinfo **res);
TINYNET_API void tnet_freeaddrinfo(struct addrinfo *ai);
TINYNET_API int tnet_get_sockaddr(tnet_fd_t fd, struct sockaddr_storage *result);

View File

@ -50,9 +50,9 @@
#define RUN_TEST_AUTH 0
#define RUN_TEST_STUN 0
#define RUN_TEST_NAT 0
#define RUN_TEST_IFACES 0
#define RUN_TEST_IFACES 1
#define RUN_TEST_DNS 0
#define RUN_TEST_DHCP 1
#define RUN_TEST_DHCP 0
#define RUN_TEST_DHCP6 0
#ifdef _WIN32_WCE

View File

@ -22,6 +22,25 @@
#ifndef TNET_TEST_IFACES_H
#define TNET_TEST_IFACES_H
void test_faces_bestsource()
{
tnet_ip_t source;
// IPv6
if(!tnet_getbestsource("2a01:e35:8b32:7050:212:f0ff:fe4c:3ea1", tnet_socket_type_udp_ipv6, &source)){
TSK_DEBUG_INFO("Best IPv6 source is [%s]", source);
}
else{
TSK_DEBUG_ERROR("Failed to get best IPv6 source.");
}
// IPv4
if(!tnet_getbestsource("192.168.0.11", tnet_socket_type_udp_ipv4, &source)){
TSK_DEBUG_INFO("Best IPv4 source is [%s]", source);
}
else{
TSK_DEBUG_ERROR("Failed to get best IPv4 source.");
}
}
void test_ifaces_dump_ifaces()
{
tnet_interfaces_L_t* ifaces = tnet_get_interfaces();
@ -67,6 +86,7 @@ void test_ifaces_dump_addresses()
void test_ifaces()
{
test_faces_bestsource();
test_ifaces_dump_ifaces();
test_ifaces_dump_addresses();
}

View File

@ -13,6 +13,7 @@ OBJS = tsk.o\
tsk_buffer.o\
tsk_condwait.o\
tsk_debug.o\
tsk_fsm.o\
tsk_heap.o\
tsk_hmac.o\
tsk_list.o\
@ -23,6 +24,7 @@ OBJS = tsk.o\
tsk_params.o\
tsk_ppfcs16.o\
tsk_ppfcs32.o\
tsk_ragel_state.o\
tsk_runnable.o\
tsk_safeobj.o\
tsk_semaphore.o\

View File

@ -99,19 +99,19 @@ void* tsk_object_new2(const tsk_object_def_t *objdef, va_list* ap)
size_t tsk_object_sizeof(const void *self)
{
const tsk_object_def_t **objdef = self;
const tsk_object_def_t **objdef = (const tsk_object_def_t **)self;
if(objdef && *objdef){
return (*objdef)->size;
}
else{
TSK_DEBUG_ERROR("NULL tsk obkect.");
TSK_DEBUG_ERROR("NULL object definition.");
return 0;
}
}
int tsk_object_cmp(const void *self, const void *object)
{
const tsk_object_def_t **objdef = self;
const tsk_object_def_t **objdef = (const tsk_object_def_t **)self;
if(objdef && *objdef && (*objdef)->objcmp){
return (*objdef)->objcmp(self, object);

View File

@ -80,7 +80,7 @@ TSK_BEGIN_DECLS
{ \
char* tmp = tsk_calloc(len+1, sizeof(char)); \
memcpy(tmp, tag_start, len); \
retval = (##type)##func(tmp); \
retval = (type) func(tmp); \
free(tmp); \
} \
}

View File

@ -38,6 +38,9 @@
TSIP_BEGIN_DECLS
//FD
struct tsip_message_s;
#define TSIP_OPERATION_CREATE(stack, ...) tsk_object_new(tsip_operation_def_t, stack, __VA_ARGS__)
typedef uint64_t tsip_operation_id_t;

View File

@ -5,7 +5,7 @@ export OPTIONS="-C -L -T0"
#export OPTIONS="-C -L -G2"
# SIP/SIPS/TEL URI parser
#ragel.exe $OPTIONS -o ../src/parsers/tsip_parser_uri.c tsip_parser_uri.rl
ragel.exe $OPTIONS -o ../src/parsers/tsip_parser_uri.c tsip_parser_uri.rl
# SIP message (both requests an responses) parser.
ragel.exe $OPTIONS -o ../src/parsers/tsip_parser_message.c tsip_parser_message.rl
@ -15,106 +15,106 @@ ragel.exe $OPTIONS -o ../src/parsers/tsip_parser_header.c tsip_parser_header.rl
# ==Allow
##ragel.exe $OPTIONS -o ../src/headers/tsip_header_Allow.c tsip_parser_header_Allow.rl
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Allow.c tsip_parser_header_Allow.rl
# ==Allow-Events
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Allow_Events.c tsip_parser_header_Allow_Events.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Allow_Events.c tsip_parser_header_Allow_Events.rl
# ==Authorization
#######ragel.exe $OPTIONS -o ../src/headers/tsip_header_Authorization.c tsip_parser_header_Authorization.rl
######ragel.exe $OPTIONS -o ../src/headers/tsip_header_Authorization.c tsip_parser_header_Authorization.rl
# ==Call-ID
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Call_ID.c tsip_parser_header_Call_ID.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Call_ID.c tsip_parser_header_Call_ID.rl
# ==Content-Length
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Content_Length.c tsip_parser_header_Content_Length.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Content_Length.c tsip_parser_header_Content_Length.rl
# ==Content-Type
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Content_Type.c tsip_parser_header_Content_Type.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Content_Type.c tsip_parser_header_Content_Type.rl
# ==Contact
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Contact.c tsip_parser_header_Contact.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Contact.c tsip_parser_header_Contact.rl
# ==CSeq
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_CSeq.c tsip_parser_header_CSeq.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_CSeq.c tsip_parser_header_CSeq.rl
# ==Event
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Event.c tsip_parser_header_Event.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Event.c tsip_parser_header_Event.rl
# ==Expires
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Expires.c tsip_parser_header_Expires.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Expires.c tsip_parser_header_Expires.rl
# ==From
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_From.c tsip_parser_header_From.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_From.c tsip_parser_header_From.rl
# ==Max-Forwards
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Max_Forwards.c tsip_parser_header_Max_Forwards.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Max_Forwards.c tsip_parser_header_Max_Forwards.rl
# ==Min-Expires
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Min_Expires.c tsip_parser_header_Min_Expires.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Min_Expires.c tsip_parser_header_Min_Expires.rl
# ==Path
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Path.c tsip_parser_header_Path.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Path.c tsip_parser_header_Path.rl
# ==P-Access-Network-Info
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Access_Network_Info.c tsip_parser_header_P_Access_Network_Info.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Access_Network_Info.c tsip_parser_header_P_Access_Network_Info.rl
# ==P-Asserted-Identity
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Asserted_Identity.c tsip_parser_header_P_Asserted_Identity.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Asserted_Identity.c tsip_parser_header_P_Asserted_Identity.rl
# ==P-Associated-URI
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Associated_URI.c tsip_parser_header_P_Associated_URI.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Associated_URI.c tsip_parser_header_P_Associated_URI.rl
# ==P-Charging-Function-Addresses
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Charging_Function_Addresses.c tsip_parser_header_P_Charging_Function_Addresses.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Charging_Function_Addresses.c tsip_parser_header_P_Charging_Function_Addresses.rl
# ==P-Preferred-Identity
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Preferred_Identity.c tsip_parser_header_P_Preferred_Identity.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_P_Preferred_Identity.c tsip_parser_header_P_Preferred_Identity.rl
# ==Privacy
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Privacy.c tsip_parser_header_Privacy.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Privacy.c tsip_parser_header_Privacy.rl
# ==Proxy-Authenticate
#########ragel.exe $OPTIONS -o ../src/headers/tsip_header_Proxy_Authenticate.c tsip_parser_header_Proxy_Authenticate.rl
########ragel.exe $OPTIONS -o ../src/headers/tsip_header_Proxy_Authenticate.c tsip_parser_header_Proxy_Authenticate.rl
# ==Proxy-Authorization
##########ragel.exe $OPTIONS -o ../src/headers/tsip_header_Proxy_Authorization.c tsip_parser_header_Proxy_Authorization.rl
#########ragel.exe $OPTIONS -o ../src/headers/tsip_header_Proxy_Authorization.c tsip_parser_header_Proxy_Authorization.rl
# ==Record-Route
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Record_Route.c tsip_parser_header_Record_Route.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Record_Route.c tsip_parser_header_Record_Route.rl
# ==Require
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Require.c tsip_parser_header_Require.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Require.c tsip_parser_header_Require.rl
# == Server
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Server.c tsip_parser_header_Server.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Server.c tsip_parser_header_Server.rl
# == Route
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Route.c tsip_parser_header_Route.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Route.c tsip_parser_header_Route.rl
# == Security-Client
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Security_Client.c tsip_parser_header_Security_Client.rl
# == Service-Route
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Service_Route.c tsip_parser_header_Service_Route.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Service_Route.c tsip_parser_header_Service_Route.rl
# ==Subscription-State
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Subscription_State.c tsip_parser_header_Subscription_State.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Subscription_State.c tsip_parser_header_Subscription_State.rl
# ==Supported
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Supported.c tsip_parser_header_Supported.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Supported.c tsip_parser_header_Supported.rl
# ==To
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_To.c tsip_parser_header_To.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_To.c tsip_parser_header_To.rl
# ==User-Agent
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_User_Agent.c tsip_parser_header_User_Agent.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_User_Agent.c tsip_parser_header_User_Agent.rl
# ==Via
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Via.c tsip_parser_header_Via.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Via.c tsip_parser_header_Via.rl
# ==Warning
#ragel.exe $OPTIONS -o ../src/headers/tsip_header_Warning.c tsip_parser_header_Warning.rl
ragel.exe $OPTIONS -o ../src/headers/tsip_header_Warning.c tsip_parser_header_Warning.rl
# ==WWW-Authenticate
##########ragel.exe $OPTIONS -o ../src/headers/tsip_header_WWW_Authenticate.c tsip_parser_header_WWW_Authenticate.rl
#########ragel.exe $OPTIONS -o ../src/headers/tsip_header_WWW_Authenticate.c tsip_parser_header_WWW_Authenticate.rl

View File

@ -156,3 +156,4 @@ static const tsk_object_def_t tsip_header_CSeq_def_s =
0
};
const void *tsip_header_CSeq_def_t = &tsip_header_CSeq_def_s;

View File

@ -149,3 +149,4 @@ static const tsk_object_def_t tsip_header_Content_Length_def_s =
0
};
const void *tsip_header_Content_Length_def_t = &tsip_header_Content_Length_def_s;

View File

@ -175,3 +175,4 @@ static const tsk_object_def_t tsip_header_Content_Type_def_s =
0
};
const void *tsip_header_Content_Type_def_t = &tsip_header_Content_Type_def_s;

View File

@ -167,3 +167,4 @@ static const tsk_object_def_t tsip_header_Event_def_s =
0
};
const void *tsip_header_Event_def_t = &tsip_header_Event_def_s;

View File

@ -152,3 +152,4 @@ static const tsk_object_def_t tsip_header_Expires_def_s =
0
};
const void *tsip_header_Expires_def_t = &tsip_header_Expires_def_s;

View File

@ -191,3 +191,4 @@ static const tsk_object_def_t tsip_header_From_def_s =
0
};
const void *tsip_header_From_def_t = &tsip_header_From_def_s;

View File

@ -328,3 +328,4 @@ static const tsk_object_def_t tsip_header_CSeq_def_s =
0
};
const void *tsip_header_CSeq_def_t = &tsip_header_CSeq_def_s;

View File

@ -314,3 +314,4 @@ static const tsk_object_def_t tsip_header_Content_Length_def_s =
0
};
const void *tsip_header_Content_Length_def_t = &tsip_header_Content_Length_def_s;

View File

@ -425,3 +425,4 @@ static const tsk_object_def_t tsip_header_Content_Type_def_s =
0
};
const void *tsip_header_Content_Type_def_t = &tsip_header_Content_Type_def_s;

View File

@ -466,3 +466,4 @@ static const tsk_object_def_t tsip_header_Event_def_s =
0
};
const void *tsip_header_Event_def_t = &tsip_header_Event_def_s;

View File

@ -306,3 +306,4 @@ static const tsk_object_def_t tsip_header_Expires_def_s =
0
};
const void *tsip_header_Expires_def_t = &tsip_header_Expires_def_s;

View File

@ -584,3 +584,4 @@ static const tsk_object_def_t tsip_header_From_def_s =
0
};
const void *tsip_header_From_def_t = &tsip_header_From_def_s;

View File

@ -23,11 +23,11 @@ OBJS = \
###################
## api
###################
OBJS += api/tsip_invite.o\
api/tsip_message.o\
api/tsip_publish.o\
api/tsip_register.o\
api/tsip_subscribe.o
OBJS += api/tsip_api_invite.o\
api/tsip_api_message.o\
api/tsip_api_publish.o\
api/tsip_api_register.o\
api/tsip_api_subscribe.o
###################
## authentication
###################
@ -147,17 +147,7 @@ OBJS += headers/tsip_header.o\
###################
OBJS += parsers/tsip_parser_header.o\
parsers/tsip_parser_message.o\
parsers/tsip_parser_uri.o\
parsers/tsip_ragel_state.o
###################
## smc
###################
OBJS += smc/tsip_dialog_register_sm.o\
smc/tsip_dialog_message_sm.o\
smc/tsip_transac_ict_sm.o\
smc/tsip_transac_ist_sm.o\
smc/tsip_transac_nict_sm.o\
smc/tsip_transac_nist_sm.o
parsers/tsip_parser_uri.o
###################
## transactions
###################

View File

@ -42,10 +42,10 @@
#define RUN_TEST_LOOP 1
#define RUN_TEST_ALL 0
#define RUN_TEST_MESSAGES 1
#define RUN_TEST_MESSAGES 0
#define RUN_TEST_URI 0
#define RUN_TEST_TRANSAC 0
#define RUN_TEST_STACK 0
#define RUN_TEST_STACK 1
#ifdef _WIN32_WCE
int _tmain(int argc, _TCHAR* argv[])

View File

@ -44,7 +44,7 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\win32\include&quot;;&quot;$(DOUBANGO_HOME)\thirdparties\win32\include\smc&quot;;&quot;$(SolutionDir)\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;;&quot;$(DOUBANGO_HOME)\tinyNET\src&quot;;&quot;$(DOUBANGO_HOME)\tinyHTTP\include&quot;"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\win32\include&quot;;&quot;$(SolutionDir)\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;;&quot;$(DOUBANGO_HOME)\tinyNET\src&quot;;&quot;$(DOUBANGO_HOME)\tinyHTTP\include&quot;"
PreprocessorDefinitions="DEBUG_LEVEL=DEBUG_LEVEL_INFO;WIN32;_DEBUG;_CONSOLE"
MinimalRebuild="true"
BasicRuntimeChecks="3"
@ -121,7 +121,7 @@
Name="VCCLCompilerTool"
ExecutionBucket="7"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\wince\include\smc&quot;;&quot;$(DOUBANGO_HOME)\thirdparties\wince\include&quot;;&quot;$(SolutionDir)\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\win32\include&quot;;&quot;$(SolutionDir)\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;;&quot;$(DOUBANGO_HOME)\tinyNET\src&quot;;&quot;$(DOUBANGO_HOME)\tinyHTTP\include&quot;"
PreprocessorDefinitions="DEBUG_LEVEL=DEBUG_LEVEL_INFO;_DEBUG;_WIN32_WCE=$(CEVER);UNDER_CE;$(PLATFORMDEFINES);WINCE;DEBUG;$(ARCHFAM);$(_ARCHFAM_);_CONSOLE"
MinimalRebuild="true"
RuntimeLibrary="0"

View File

@ -123,7 +123,7 @@ int tsip_registration_callback(const tsip_register_event_t *sipevent)
void test_stack()
{
/*
tsip_stack_handle_t *stack = tsip_stack_create(test_stack_callback,
TSIP_STACK_SET_DISPLAY_NAME("2233392625"),
TSIP_STACK_SET_PUBLIC_IDENTITY("sip:2233392625@sip2sip.info"),
@ -132,15 +132,15 @@ void test_stack()
TSIP_STACK_SET_REALM("sip:sip2sip.info"), // FIXME: without sip:
TSIP_STACK_SET_LOCAL_IP(LOCAL_IP),
//TSIP_STACK_SET_DISCOVERY_NAPTR(1),
TSIP_STACK_SET_PROXY_CSCF("proxy.sipthor.net", "udp", 0),
TSIP_STACK_SET_PROXY_CSCF("proxy.sipthor.net", "udp", 1),
//TSIP_STACK_SET_PROXY_CSCF("192.168.0.15", "udp", 0),
TSIP_STACK_SET_PROXY_CSCF_PORT(5060),
TSIP_STACK_SET_SEC_AGREE_MECH("ipsec-3gpp"),
TSIP_STACK_SET_MOBILITY("fixed"),
TSIP_STACK_SET_DEVICE_ID("DD1289FA-C3D7-47bd-A40D-F1F1B2CC5FFC"),
TSIP_STACK_SET_NETINFO("ADSL;utran-cell-id-3gpp=00000000"),
*/
/*
/*
tsip_stack_handle_t *stack = tsip_stack_create(test_stack_callback,
TSIP_STACK_SET_DISPLAY_NAME("Mamadou"),
TSIP_STACK_SET_PUBLIC_IDENTITY("sip:mamadou@ericsson.com"),
@ -149,7 +149,7 @@ void test_stack()
TSIP_STACK_SET_REALM("sip:ericsson.com"), // FIXME: without sip:
TSIP_STACK_SET_LOCAL_IP(LOCAL_IP),
//TSIP_STACK_SET_DISCOVERY_NAPTR(1),
TSIP_STACK_SET_PROXY_CSCF("192.168.0.11", "udp", 0),
TSIP_STACK_SET_PROXY_CSCF("192.168.0.11", "tcp", 0),
//TSIP_STACK_SET_PROXY_CSCF("192.168.0.15", "udp", 0),
TSIP_STACK_SET_PROXY_CSCF_PORT(5081),
TSIP_STACK_SET_SEC_AGREE_MECH("ipsec-3gpp"),
@ -157,7 +157,7 @@ void test_stack()
TSIP_STACK_SET_DEVICE_ID("DD1289FA-C3D7-47bd-A40D-F1F1B2CC5FFC"),
TSIP_STACK_SET_NETINFO("ADSL;utran-cell-id-3gpp=00000000"),
*/
/*
tsip_stack_handle_t *stack = tsip_stack_create(test_stack_callback,
TSIP_STACK_SET_DISPLAY_NAME("Mamadou"),
TSIP_STACK_SET_PUBLIC_IDENTITY("sip:mamadou@ims.inexbee.com"),
@ -173,7 +173,7 @@ void test_stack()
TSIP_STACK_SET_MOBILITY("fixed"),
TSIP_STACK_SET_DEVICE_ID("DD1289FA-C3D7-47bd-A40D-F1F1B2CC5FFC"),
TSIP_STACK_SET_NETINFO("ADSL;utran-cell-id-3gpp=00000000"),
*/
TSIP_STACK_SET_NULL());
tsip_operation_handle_t *op = TSIP_OPERATION_CREATE(stack,
@ -199,7 +199,7 @@ void test_stack()
TSIP_OPERATION_SET_PARAM("expires", "30"),
TSIP_OPERATION_SET_PARAM("package", "reg"),
TSIP_OPERATION_SET_PARAM("accept", "application/reginfo+xml"),
TSIP_OPERATION_SET_PARAM("to", "sip:mamadou@ims.inexbee.com"),
TSIP_OPERATION_SET_PARAM("to", "sip:mamadou@sip2sip.info"),
TSIP_OPERATION_SET_NULL());
tsip_subscribe(stack, op2);

View File

@ -44,7 +44,7 @@
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\win32\include&quot;;&quot;$(DOUBANGO_HOME)\thirdparties\win32\include\smc&quot;;&quot;$(DOUBANGO_HOME)\tinySIP\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;;&quot;$(DOUBANGO_HOME)\tinyNET\src&quot;;&quot;$(DOUBANGO_HOME)\tinyHTTP\include&quot;"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\win32\include&quot;;&quot;$(DOUBANGO_HOME)\tinySIP\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;;&quot;$(DOUBANGO_HOME)\tinyNET\src&quot;;&quot;$(DOUBANGO_HOME)\tinyHTTP\include&quot;"
PreprocessorDefinitions="DEBUG_LEVEL=DEBUG_LEVEL_INFO;WIN32;_DEBUG;_WINDOWS;_USRDLL;TINYSIP_EXPORTS;_WIN32_WINNT 0x0501"
MinimalRebuild="true"
RuntimeLibrary="3"
@ -120,7 +120,7 @@
Name="VCCLCompilerTool"
ExecutionBucket="7"
Optimization="0"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\wince\include\smc&quot;;&quot;$(DOUBANGO_HOME)\thirdparties\wince\include&quot;;&quot;$(DOUBANGO_HOME)\tinySIP\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;;&quot;$(DOUBANGO_HOME)\tinyNET\src&quot;;&quot;$(DOUBANGO_HOME)\tinyHTTP\include&quot;"
AdditionalIncludeDirectories="&quot;$(DOUBANGO_HOME)\thirdparties\wince\include&quot;;&quot;$(DOUBANGO_HOME)\tinySIP\include&quot;;&quot;$(DOUBANGO_HOME)\tinySAK\src&quot;;&quot;$(DOUBANGO_HOME)\tinyNET\src&quot;;&quot;$(DOUBANGO_HOME)\tinyHTTP\include&quot;"
PreprocessorDefinitions="DEBUG_LEVEL=DEBUG_LEVEL_INFO;TINYSIP_EXPORTS;_DEBUG;_WIN32_WCE=$(CEVER);UNDER_CE;$(PLATFORMDEFINES);WINCE;DEBUG;_WINDOWS;_USRDLL;$(ARCHFAM);$(_ARCHFAM_)"
MinimalRebuild="true"
RuntimeLibrary="3"