1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-06 00:13:33 +00:00

Fixed compiler warnings

This commit is contained in:
Bryan Roe
2021-08-30 14:58:22 -07:00
parent f3991cee87
commit 38d9ddc3f5
2 changed files with 2 additions and 5 deletions

View File

@@ -574,9 +574,6 @@ int kvm_init(int displayNo)
{
char tmpBuff[1024];
sprintf_s(tmpBuff, sizeof(tmpBuff), "XOpenDisplay(%s) failed, using XAUTHORITY: %s", CURRENT_XDISPLAY, getenv("XAUTHORITY"));
//fprintf(logFile, "DisplayString=%s\n", displayString);
//fprintf(logFile, "XAUTHORITY is %s", getenv("XAUTHORITY")); fflush(logFile);
//fprintf(logFile, "Error calling XOpenDisplay()\n"); fflush(logFile);
kvm_send_error(tmpBuff);
return(-1);
}
@@ -932,7 +929,6 @@ void* kvm_server_mainloop(void* parm)
eventdisplay = NULL;
Display *imagedisplay = NULL, *cursordisplay = NULL;
void *buf = NULL;
char displayString[256] = "";
int event_base = 0, error_base = 0, cursor_descriptor = -1;
ssize_t written;
XShmSegmentInfo shminfo;
@@ -944,7 +940,7 @@ void* kvm_server_mainloop(void* parm)
fd_set writeset;
XEvent XE;
unsigned short currentDisplayId;
unsigned short currentDisplayId = 0;
if (logFile) { fprintf(logFile, "Checking $DISPLAY\n"); fflush(logFile); }
for (char **env = environ; *env; ++env)

View File

@@ -3126,6 +3126,7 @@ ILibTransport_DoneState ILibStun_SendSctpPacket(struct ILibStun_Module *obj, int
int ILibStun_AddSctpChunkHeader(char* buffer, int ptr, unsigned char chunktype, unsigned char chunkflags, unsigned short chunklength)
{
if (buffer == NULL) { ILIBCRITICALEXITMSG(255, "ILibStun_AddSctpChunkHeader() Invalid Parameter"); }
if (ptr >= 12 && ((int*)buffer)[0] == 0 && ((int*)buffer)[1] == 0)
{
// This buffer contains a common buffer area, that has control flags