Commit 47796167 authored by Reinhard Tartler's avatar Reinhard Tartler

Imported nxcomp-3.4.0-6.tar.gz

Summary: Imported nxcomp-3.4.0-6.tar.gz Keywords: Imported nxcomp-3.4.0-6.tar.gz into Git repository
parent 799bf672
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
#include "Misc.h" #include "Misc.h"
#include "Unpack.h" #include "Unpack.h"
#include "Alpha.h"
#define PANIC #define PANIC
#define WARNING #define WARNING
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -268,7 +268,7 @@ int Auth::getCookie() ...@@ -268,7 +268,7 @@ int Auth::getCookie()
snprintf(line, DEFAULT_STRING_LIMIT, "%.200s", display_); snprintf(line, DEFAULT_STRING_LIMIT, "%.200s", display_);
} }
char *parameters[256]; const char *parameters[256];
parameters[0] = command; parameters[0] = command;
parameters[1] = command; parameters[1] = command;
...@@ -295,7 +295,7 @@ int Auth::getCookie() ...@@ -295,7 +295,7 @@ int Auth::getCookie()
// implementation. // implementation.
// //
FILE *data = Popen(parameters, "r"); FILE *data = Popen((char *const *) parameters, "r");
int result = -1; int result = -1;
...@@ -342,7 +342,21 @@ int Auth::getCookie() ...@@ -342,7 +342,21 @@ int Auth::getCookie()
<< "'.\n" << logofs_flush; << "'.\n" << logofs_flush;
#endif #endif
if (sscanf(line, "%*s %*s %511s", realCookie_) != 1) //
// Skip the hostname in the authority entry
// just in case it includes some white spaces.
//
char *cookie = NULL;
cookie = index(line, ':');
if (cookie == NULL)
{
cookie = line;
}
if (sscanf(cookie, "%*s %*s %511s", realCookie_) != 1)
{ {
#ifdef PANIC #ifdef PANIC
*logofs << "Auth: PANIC! Failed to identify the cookie " *logofs << "Auth: PANIC! Failed to identify the cookie "
...@@ -499,7 +513,7 @@ int Auth::checkCookie(unsigned char *buffer) ...@@ -499,7 +513,7 @@ int Auth::checkCookie(unsigned char *buffer)
return -1; return -1;
} }
char *protoName = "MIT-MAGIC-COOKIE-1"; const char *protoName = "MIT-MAGIC-COOKIE-1";
int protoSize = strlen(protoName); int protoSize = strlen(protoName);
int matchedProtoSize; int matchedProtoSize;
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
ChangeLog: ChangeLog:
nxcomp-3.4.0-6
- Solved compilation problems on Solaris.
nxcomp-3.4.0-5
- Solved compilation problems on GCC 4.4.
nxcomp-3.4.0-4
- Added reference to fixed TR02H02325.
nxcomp-3.4.0-3
- Updated copyright to year 2010.
nxcomp-3.4.0-2
- Fixed TR03G02204. Changed the parsing of X authority entries in
order to handle the case where the hostname includes white spaces.
- Fixed TR02H02325. Bug in PNG decompression on 16bpp displays.
nxcomp-3.4.0-1 nxcomp-3.4.0-1
- Opened the 3.4.0 branch based on nxcomp-3.3.0-4. - Opened the 3.4.0 branch based on nxcomp-3.3.0-4.
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -2037,10 +2037,10 @@ Split *Channel::handleSplitCommitRemove(int request, int resource, int position) ...@@ -2037,10 +2037,10 @@ Split *Channel::handleSplitCommitRemove(int request, int resource, int position)
<< ".\n" << logofs_flush; << ".\n" << logofs_flush;
#endif #endif
if (control -> isProtoStep7() == 1 && if ((control -> isProtoStep7() == 1 &&
(resource != split -> getResource() || (resource != split -> getResource() ||
request != split -> getRequest() || request != split -> getRequest() ||
position != split -> getPosition()) || position != split -> getPosition())) ||
(request != split -> getRequest() || (request != split -> getRequest() ||
position != split -> getPosition())) position != split -> getPosition()))
{ {
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -498,9 +498,9 @@ class Channel ...@@ -498,9 +498,9 @@ class Channel
int canCleanStore(MessageStore *store) int canCleanStore(MessageStore *store)
{ {
return (store -> getSize() > 0 && (store -> getRemoteStorageSize() > return ((store -> getSize() > 0 && (store -> getRemoteStorageSize() >
(control -> RemoteTotalStorageSize / 100 * store -> (control -> RemoteTotalStorageSize / 100 * store ->
cacheLowerThreshold)) || (store -> getLocalStorageSize() > cacheLowerThreshold))) || (store -> getLocalStorageSize() >
(control -> LocalTotalStorageSize / 100 * store -> (control -> LocalTotalStorageSize / 100 * store ->
cacheLowerThreshold))); cacheLowerThreshold)));
} }
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -69,7 +69,8 @@ extern void InstallSignals(); ...@@ -69,7 +69,8 @@ extern void InstallSignals();
extern char *GetClientPath(); extern char *GetClientPath();
extern int CheckParent(char *name, char *type, int parent); extern int CheckParent(const char *name, const char *type,
int parent);
#ifdef __sun #ifdef __sun
extern char **environ; extern char **environ;
...@@ -81,19 +82,23 @@ extern char **environ; ...@@ -81,19 +82,23 @@ extern char **environ;
// have been disabled in the main process. // have been disabled in the main process.
// //
static void SystemCleanup(char *name); static void SystemCleanup(const char *name);
// //
// Release all objects allocated in the // Release all objects allocated in the
// heap. // heap.
static void MemoryCleanup(char *name); static void MemoryCleanup(const char *name);
// //
// Remove 'name' from the environment. // Remove 'name' from the environment.
// //
static int UnsetEnv(char *name); static int UnsetEnv(const char *name);
static int NXTransKeeperHandler(int signal);
static void NXTransKeeperCheck();
// //
// Start a nxclient process in dialog mode. // Start a nxclient process in dialog mode.
...@@ -926,7 +931,7 @@ int NXTransKeeper(int caches, int images, const char *root) ...@@ -926,7 +931,7 @@ int NXTransKeeper(int caches, int images, const char *root)
exit(0); exit(0);
} }
void SystemCleanup(char *name) void SystemCleanup(const char *name)
{ {
#ifdef TEST #ifdef TEST
*logofs << name << ": Performing system cleanup in process " *logofs << name << ": Performing system cleanup in process "
...@@ -942,7 +947,7 @@ void SystemCleanup(char *name) ...@@ -942,7 +947,7 @@ void SystemCleanup(char *name)
InstallSignals(); InstallSignals();
} }
void MemoryCleanup(char *name) void MemoryCleanup(const char *name)
{ {
#ifdef TEST #ifdef TEST
*logofs << name << ": Performing memory cleanup in process " *logofs << name << ": Performing memory cleanup in process "
...@@ -977,7 +982,7 @@ void MemoryCleanup(char *name) ...@@ -977,7 +982,7 @@ void MemoryCleanup(char *name)
EnableSignals(); EnableSignals();
} }
int UnsetEnv(char *name) int UnsetEnv(const char *name)
{ {
int result; int result;
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -5646,9 +5646,9 @@ int ClientChannel::handleSplitChecksum(EncodeBuffer &encodeBuffer, T_checksum ch ...@@ -5646,9 +5646,9 @@ int ClientChannel::handleSplitChecksum(EncodeBuffer &encodeBuffer, T_checksum ch
// persistent image cache is enabled. // persistent image cache is enabled.
// //
if (control -> ImageCacheEnableLoad == 1 || if ((control -> ImageCacheEnableLoad == 1 ||
control -> ImageCacheEnableSave == 1 && control -> ImageCacheEnableSave == 1) &&
enableLoad_ == 1 || enableSave_ == 1) (enableLoad_ == 1 || enableSave_ == 1))
{ {
encodeBuffer.encodeBoolValue(1); encodeBuffer.encodeBoolValue(1);
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
#include "Misc.h" #include "Misc.h"
#include "Unpack.h" #include "Unpack.h"
#include "Colormap.h"
#define PANIC #define PANIC
#define WARNING #define WARNING
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -17,6 +17,7 @@ ...@@ -17,6 +17,7 @@
#include <unistd.h> #include <unistd.h>
#include "Fork.h"
#include "Misc.h" #include "Misc.h"
#include "Timestamp.h" #include "Timestamp.h"
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -20,4 +20,4 @@ ...@@ -20,4 +20,4 @@
// often on Cygwin. // often on Cygwin.
// //
int Fork(); extern int Fork();
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -91,6 +91,8 @@ static int DecompressJpeg24(unsigned char *compressedData, int compressedLen, ...@@ -91,6 +91,8 @@ static int DecompressJpeg24(unsigned char *compressedData, int compressedLen,
static int DecompressJpeg32(unsigned char *compressedData, int compressedLen, static int DecompressJpeg32(unsigned char *compressedData, int compressedLen,
unsigned int w, unsigned int h, unsigned char *dstBuf, int byteOrder); unsigned int w, unsigned int h, unsigned char *dstBuf, int byteOrder);
void UnpackJpegErrorHandler(j_common_ptr cinfo);
// //
// Colormap stuff. // Colormap stuff.
// //
...@@ -142,8 +144,8 @@ int UnpackJpeg(T_geometry *geometry, unsigned char method, unsigned char *srcDat ...@@ -142,8 +144,8 @@ int UnpackJpeg(T_geometry *geometry, unsigned char method, unsigned char *srcDat
// Check if data is coming from a failed unsplit. // Check if data is coming from a failed unsplit.
// //
if (srcSize < 2 || srcData[0] == SPLIT_PATTERN && if (srcSize < 2 || (srcData[0] == SPLIT_PATTERN &&
srcData[1] == SPLIT_PATTERN) srcData[1] == SPLIT_PATTERN))
{ {
#ifdef WARNING #ifdef WARNING
*logofs << "UnpackJpeg: WARNING! Skipping unpack of dummy data.\n" *logofs << "UnpackJpeg: WARNING! Skipping unpack of dummy data.\n"
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
Copyright (c) 2001, 2009 NoMachine - http://www.nomachine.com/. Copyright (c) 2001, 2010 NoMachine - http://www.nomachine.com/.
NXCOMP library and NX extensions to X are copyright of NoMachine. NXCOMP library and NX extensions to X are copyright of NoMachine.
Redistribution and use of this software is allowed according to the Redistribution and use of this software is allowed according to the
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
......
/**************************************************************************/ /**************************************************************************/
/* */ /* */
/* Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. */ /* Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. */
/* */ /* */
/* NXCOMP, NX protocol compression and NX extensions to this software */ /* NXCOMP, NX protocol compression and NX extensions to this software */
/* are copyright of NoMachine. Redistribution and use of the present */ /* are copyright of NoMachine. Redistribution and use of the present */
...@@ -354,7 +354,7 @@ static int HandleChild(int child); ...@@ -354,7 +354,7 @@ static int HandleChild(int child);
static int CheckChild(int pid, int status); static int CheckChild(int pid, int status);
static int WaitChild(int child, const char *label, int force); static int WaitChild(int child, const char *label, int force);
int CheckParent(char *name, char *type, int parent); int CheckParent(const char *name, const char *type, int parent);
void RegisterChild(int child); void RegisterChild(int child);
...@@ -1514,9 +1514,9 @@ int NXTransClose(int fd) ...@@ -1514,9 +1514,9 @@ int NXTransClose(int fd)
* end of the socket pair. * end of the socket pair.
*/ */
if (control != NULL && (agent != NULL && if (control != NULL && ((agent != NULL &&
(fd == agentFD[0] || fd == NX_FD_ANY)) || (fd == agentFD[0] || fd == NX_FD_ANY)) ||
(fd == proxyFD || fd == NX_FD_ANY)) (fd == proxyFD || fd == NX_FD_ANY)))
{ {
if (proxy != NULL) if (proxy != NULL)
{ {
...@@ -1551,9 +1551,9 @@ int NXTransDestroy(int fd) ...@@ -1551,9 +1551,9 @@ int NXTransDestroy(int fd)
logofs = &cerr; logofs = &cerr;
} }
if (control != NULL && (agent != NULL && if (control != NULL && ((agent != NULL &&
(fd == agentFD[0] || fd == NX_FD_ANY)) || (fd == agentFD[0] || fd == NX_FD_ANY)) ||
(fd == proxyFD || fd == NX_FD_ANY)) (fd == proxyFD || fd == NX_FD_ANY)))
{ {
// //
// Shut down the X connections and // Shut down the X connections and
...@@ -6396,7 +6396,7 @@ void RegisterChild(int child) ...@@ -6396,7 +6396,7 @@ void RegisterChild(int child)
lastChild = child; lastChild = child;
} }
int CheckParent(char *name, char *type, int parent) int CheckParent(const char *name, const char *type, int parent)
{ {
if (parent != getppid() || parent == 1) if (parent != getppid() || parent == 1)
{ {
...@@ -9995,8 +9995,8 @@ char *GetLastCache(char *listBuffer, const char *searchPath) ...@@ -9995,8 +9995,8 @@ char *GetLastCache(char *listBuffer, const char *searchPath)
*selectedName = '\0'; *selectedName = '\0';
char *localPrefix; const char *localPrefix;
char *remotePrefix; const char *remotePrefix;
if (control -> ProxyMode == proxy_client) if (control -> ProxyMode == proxy_client)
{ {
...@@ -10979,7 +10979,7 @@ int ParsePackOption(const char *opt) ...@@ -10979,7 +10979,7 @@ int ParsePackOption(const char *opt)
packMethod == PACK_LOSSLESS || packMethod == PACK_LOSSLESS ||
packMethod == PACK_ADAPTIVE) packMethod == PACK_ADAPTIVE)
{ {
char *dash = rindex(opt, '-'); const char *dash = rindex(opt, '-');
if (dash != NULL && strlen(dash) == 2 && if (dash != NULL && strlen(dash) == 2 &&
*(dash + 1) >= '0' && *(dash + 1) <= '9') *(dash + 1) >= '0' && *(dash + 1) <= '9')
...@@ -13927,7 +13927,7 @@ void PrintProcessInfo() ...@@ -13927,7 +13927,7 @@ void PrintProcessInfo()
<< "." << control -> LocalVersionMinor << "." << "." << control -> LocalVersionMinor << "."
<< control -> LocalVersionPatch << "\n\n"; << control -> LocalVersionPatch << "\n\n";
cerr << "Copyright (C) 2001, 2007 NoMachine.\n" cerr << "Copyright (C) 2001, 2010 NoMachine.\n"
<< "See http://www.nomachine.com/ for more information.\n\n"; << "See http://www.nomachine.com/ for more information.\n\n";
} }
...@@ -14080,8 +14080,8 @@ void PrintConnectionInfo() ...@@ -14080,8 +14080,8 @@ void PrintConnectionInfo()
} }
if (control -> ProxyMode == proxy_client && if (control -> ProxyMode == proxy_client &&
useUnixSocket > 0 || useTcpSocket > 0 || (useUnixSocket > 0 || useTcpSocket > 0 ||
useAgentSocket > 0) useAgentSocket > 0))
{ {
cerr << "Info" << ": Listening to X11 connections " cerr << "Info" << ": Listening to X11 connections "
<< "on display ':" << xPort << "'.\n"; << "on display ':" << xPort << "'.\n";
...@@ -15764,8 +15764,8 @@ static void handleAlertInLoop() ...@@ -15764,8 +15764,8 @@ static void handleAlertInLoop()
int replace = 1; int replace = 1;
int local = 1; int local = 1;
char *message; const char *message;
char *type; const char *type;
switch (lastAlert.code) switch (lastAlert.code)
{ {
...@@ -16218,7 +16218,7 @@ static inline void handleReadableInLoop(int &resultFDs, fd_set &readSet) ...@@ -16218,7 +16218,7 @@ static inline void handleReadableInLoop(int &resultFDs, fd_set &readSet)
{ {
T_channel_type type = channel_none; T_channel_type type = channel_none;
char *label = NULL; const char *label = NULL;
int domain = -1; int domain = -1;
int fd = -1; int fd = -1;
......
############################################################################ ############################################################################
# # # #
# Copyright (c) 2001, 2009 NoMachine, http://www.nomachine.com/. # # Copyright (c) 2001, 2010 NoMachine, http://www.nomachine.com/. #
# # # #
# NXCOMP, NX protocol compression and NX extensions to this software # # NXCOMP, NX protocol compression and NX extensions to this software #
# are copyright of NoMachine. Redistribution and use of the present # # are copyright of NoMachine. Redistribution and use of the present #
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment