removed conflict markers from merge
This commit is contained in:
@@ -254,11 +254,7 @@ osx_static_lib: lwip $(OBJS)
|
|||||||
else
|
else
|
||||||
osx_static_lib: pico $(OBJS)
|
osx_static_lib: pico $(OBJS)
|
||||||
$(CXX) $(CXXFLAGS) $(STACK_FLAGS) $(DEFS) $(INCLUDES) $(ZTFLAGS) -DSDK_SERVICE -DSDK -DSDK_BUNDLED $(PICO_DRIVER_FILES) $(SDK_INTERCEPT_C_FILES) $(SDK_SERVICE_CPP_FILES) src/service.cpp -c
|
$(CXX) $(CXXFLAGS) $(STACK_FLAGS) $(DEFS) $(INCLUDES) $(ZTFLAGS) -DSDK_SERVICE -DSDK -DSDK_BUNDLED $(PICO_DRIVER_FILES) $(SDK_INTERCEPT_C_FILES) $(SDK_SERVICE_CPP_FILES) src/service.cpp -c
|
||||||
<<<<<<< HEAD
|
|
||||||
libtool -static -o build/libzt.a picotcp.o proxy.o tap.o one.o OneService.o service.o sockets.o rpc.o intercept.o OneService.o $(OBJS)
|
|
||||||
=======
|
|
||||||
libtool -static -o build/libzt.a picotcp.o proxy.o tap.o one.o OneService.o service.o sockets.o rpc.o intercept.o $(OBJS)
|
libtool -static -o build/libzt.a picotcp.o proxy.o tap.o one.o OneService.o service.o sockets.o rpc.o intercept.o $(OBJS)
|
||||||
>>>>>>> dev
|
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Builds zts_* library tests
|
# Builds zts_* library tests
|
||||||
|
|||||||
16
src/sdk.h
16
src/sdk.h
@@ -55,37 +55,23 @@
|
|||||||
#endif
|
#endif
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
<<<<<<< HEAD
|
|
||||||
#include <sys/socket.h>
|
#include <sys/socket.h>
|
||||||
#include <stdbool.h>
|
#include <stdbool.h>
|
||||||
|
|
||||||
#define SETSOCKOPT_SIG int fd, int level, int optname, const void *optval, socklen_t optlen
|
|
||||||
#define GETSOCKOPT_SIG int fd, int level, int optname, void *optval, socklen_t *optlen
|
|
||||||
|
|
||||||
=======
|
|
||||||
// ------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------
|
||||||
// -------------- Socket API function signatures for convenience ----------------
|
// -------------- Socket API function signatures for convenience ----------------
|
||||||
// ------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------
|
||||||
|
|
||||||
#define SETSOCKOPT_SIG int fd, int level, int optname, const void *optval, socklen_t optlen
|
#define SETSOCKOPT_SIG int fd, int level, int optname, const void *optval, socklen_t optlen
|
||||||
#define GETSOCKOPT_SIG int fd, int level, int optname, void *optval, socklen_t *optlen
|
#define GETSOCKOPT_SIG int fd, int level, int optname, void *optval, socklen_t *optlen
|
||||||
>>>>>>> dev
|
|
||||||
#define SENDMSG_SIG int fd, const struct msghdr *msg, int flags
|
#define SENDMSG_SIG int fd, const struct msghdr *msg, int flags
|
||||||
#define SENDTO_SIG int fd, const void *buf, size_t len, int flags, const struct sockaddr *addr, socklen_t addrlen
|
#define SENDTO_SIG int fd, const void *buf, size_t len, int flags, const struct sockaddr *addr, socklen_t addrlen
|
||||||
#define RECV_SIG int fd, void *buf, size_t len, int flags
|
#define RECV_SIG int fd, void *buf, size_t len, int flags
|
||||||
#define RECVFROM_SIG int fd, void *buf, size_t len, int flags, struct sockaddr *addr, socklen_t *addrlen
|
#define RECVFROM_SIG int fd, void *buf, size_t len, int flags, struct sockaddr *addr, socklen_t *addrlen
|
||||||
#define RECVMSG_SIG int fd, struct msghdr *msg,int flags
|
#define RECVMSG_SIG int fd, struct msghdr *msg,int flags
|
||||||
<<<<<<< HEAD
|
|
||||||
|
|
||||||
#define SEND_SIG int fd, const void *buf, size_t len, int flags
|
#define SEND_SIG int fd, const void *buf, size_t len, int flags
|
||||||
#define WRITE_SIG int fd, const void *buf, size_t len
|
#define WRITE_SIG int fd, const void *buf, size_t len
|
||||||
#define READ_SIG int fd, void *buf, size_t len
|
#define READ_SIG int fd, void *buf, size_t len
|
||||||
|
|
||||||
=======
|
|
||||||
#define SEND_SIG int fd, const void *buf, size_t len, int flags
|
|
||||||
#define WRITE_SIG int fd, const void *buf, size_t len
|
|
||||||
#define READ_SIG int fd, void *buf, size_t len
|
|
||||||
>>>>>>> dev
|
|
||||||
#define SOCKET_SIG int socket_family, int socket_type, int protocol
|
#define SOCKET_SIG int socket_family, int socket_type, int protocol
|
||||||
#define CONNECT_SIG int fd, const struct sockaddr *addr, socklen_t addrlen
|
#define CONNECT_SIG int fd, const struct sockaddr *addr, socklen_t addrlen
|
||||||
#define BIND_SIG int fd, const struct sockaddr *addr, socklen_t addrlen
|
#define BIND_SIG int fd, const struct sockaddr *addr, socklen_t addrlen
|
||||||
@@ -266,4 +252,4 @@ ssize_t zts_recvmsg(RECVMSG_SIG);
|
|||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#endif // _ZT_SDK_H
|
#endif // _ZT_SDK_H
|
||||||
|
|||||||
@@ -237,7 +237,7 @@ void zts_get_ipv6_address(const char *nwid, char *addrstr)
|
|||||||
int zts_get_device_id(char *devID) {
|
int zts_get_device_id(char *devID) {
|
||||||
if(zt1Service) {
|
if(zt1Service) {
|
||||||
char id[10];
|
char id[10];
|
||||||
sprintf(id, "%lx",zt1Service->getNode()->address());
|
sprintf(id, "%llx",zt1Service->getNode()->address());
|
||||||
memcpy(devID, id, 10);
|
memcpy(devID, id, 10);
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
@@ -473,7 +473,7 @@ void zts_start_service(const char *path)
|
|||||||
|
|
||||||
|
|
||||||
// ------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------
|
||||||
// ------------------------------- zts_start_service ----------------------------
|
// --------------------------- zts_start_core_service ---------------------------
|
||||||
// ------------------------------------------------------------------------------
|
// ------------------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
@@ -485,13 +485,12 @@ void *zts_start_core_service(void *thread_id) {
|
|||||||
homeDir = std::string((char*)thread_id);
|
homeDir = std::string((char*)thread_id);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
char current_dir[MAX_DIR_SZ];
|
|
||||||
|
|
||||||
//#if defined(SDK_BUNDLED) && !defined(__ANDROID__)
|
//#if defined(SDK_BUNDLED) && !defined(__ANDROID__)
|
||||||
// set_intercept_status(INTERCEPT_DISABLED); // Ignore network calls from ZT service
|
// set_intercept_status(INTERCEPT_DISABLED); // Ignore network calls from ZT service
|
||||||
//#endif
|
//#endif
|
||||||
|
|
||||||
#if defined(__IOS__)
|
#if defined(__IOS__)
|
||||||
|
char current_dir[MAX_DIR_SZ];
|
||||||
// Go to the app's data directory so we can shorten the sun_path we bind to
|
// Go to the app's data directory so we can shorten the sun_path we bind to
|
||||||
getcwd(current_dir, MAX_DIR_SZ);
|
getcwd(current_dir, MAX_DIR_SZ);
|
||||||
std::string targetDir = homeDir; // + "/../../";
|
std::string targetDir = homeDir; // + "/../../";
|
||||||
@@ -500,6 +499,7 @@ void *zts_start_core_service(void *thread_id) {
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
#if defined(__UNITY_3D__)
|
#if defined(__UNITY_3D__)
|
||||||
|
char current_dir[MAX_DIR_SZ];
|
||||||
getcwd(current_dir, MAX_DIR_SZ);
|
getcwd(current_dir, MAX_DIR_SZ);
|
||||||
chdir(service_path.c_str());
|
chdir(service_path.c_str());
|
||||||
homeDir = current_dir; // homeDir shall be current_dir
|
homeDir = current_dir; // homeDir shall be current_dir
|
||||||
|
|||||||
Reference in New Issue
Block a user