temporary patch for bad recvfrom return values, plus removal of old includes

This commit is contained in:
Joseph Henry
2017-03-08 15:13:13 -08:00
parent 905a822b05
commit f2a5b09179
5 changed files with 4 additions and 6 deletions

View File

@@ -1 +0,0 @@
#define ZTSDK_BUILD_VERSION 44

View File

@@ -30,7 +30,7 @@
#ifndef _SDK_DEBUG_H_ #ifndef _SDK_DEBUG_H_
#define _SDK_DEBUG_H_ #define _SDK_DEBUG_H_
#define DEBUG_LEVEL 4 // Set this to adjust what you'd like to see in the debug traces #define DEBUG_LEVEL 1 // Set this to adjust what you'd like to see in the debug traces
#define MSG_ERROR 1 // Errors #define MSG_ERROR 1 // Errors
#define MSG_TRANSFER 2 // RX/TX specific statements #define MSG_TRANSFER 2 // RX/TX specific statements
@@ -106,6 +106,8 @@ extern "C" {
#else #else
#define DEBUG_INFO(fmt, args...) #define DEBUG_INFO(fmt, args...)
#define DEBUG_BLANK(fmt, args...) #define DEBUG_BLANK(fmt, args...)
#define DEBUG_ATTN(fmt, args...)
#define DEBUG_STACK(fmt, args...)
#endif #endif
#if DEBUG_LEVEL >= MSG_TRANSFER #if DEBUG_LEVEL >= MSG_TRANSFER
#if defined(__ANDROID__) #if defined(__ANDROID__)

View File

@@ -76,8 +76,6 @@
#include <jni.h> #include <jni.h>
#endif #endif
#include "build.h"
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {
#endif #endif

View File

@@ -49,7 +49,6 @@
#include "tap.hpp" #include "tap.hpp"
#include "sdk.h" #include "sdk.h"
#include "debug.h" #include "debug.h"
#include "build.h"
#ifdef __cplusplus #ifdef __cplusplus
extern "C" { extern "C" {

View File

@@ -316,7 +316,7 @@ int (*realclose)(CLOSE_SIG);
else { else {
perror("read:\n"); perror("read:\n");
} }
return tmpsz; return tmpsz <= ZT_MAX_MTU ? tmpsz : -1;
} }
//#endif //#endif