aboutsummaryrefslogtreecommitdiff
path: root/nxcomp/Loop.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Cygwin nxcomp: Use Cygwin un.hMike DePaulo2017-03-291-2/+1
| | | | | Cygwin has modified it over the years. Fixes FTBFS #394
* nxcomp/Loop.cpp: Allow nx/nx:<disp> as DISPLAY variable (i.e. an empty nx/nx ↵Mike Gabriel2017-03-021-1/+2
| | | | options string.
* nxcomp/Loop.cpp: Ignore, options= nx/nx parameter, if file options path ↵Mike Gabriel2017-03-021-1/+1
| | | | | | starts with /dev/, /proc/, or /sys/. Partially resolved ArcticaProject/nx-libs#51.
* Make nxagent only bind to loopback when requestedVadim Troshchinskiy2016-12-141-4/+8
|
* Fix reversed logic in acceptHost settingVadim Troshchinskiy2016-12-131-2/+2
|
* Slave channel implementationVadim Troshchinskiy2016-10-281-1/+3
| | | | | | | | When enabled and a connection is made to the port, launches the process specified in NX_SLAVE_CMD on the other side, and connects stdin and stdout to the socket. This is used for VM/client and client/VM communication.
* Loop.cpp: Fix output of SetCore()Ulrich Sibiller2016-10-201-3/+3
|
* Fix nxproxy hostname parsing.Vadim Troshchinskiyddd2016-10-071-3/+3
| | | | | Fixes ArcticaProject/nx-libs#207 Closes ArcticaProject/nx-libs#216
* Check if unixPath is NULL before accessing it; this fixes crashing of ↵Vadim Troshchinskiy2016-10-071-1/+1
| | | | | | | nxagent when TEST is enabled. Fixes ArcticaProject/nx-libs#217. Closes ArcticaProject/nx-libs#218.
* nxcomp/Loop.cpp: We have PrintVersionInfo(), why not use it? Use endl ↵Mike Gabriel2016-08-261-6/+9
| | | | instead of \n for EOLs when streaming application's preamble to stderr.
* nxcomp/Loop.cpp: Mention DXPC copyright holders on application (i.e. ↵Mike Gabriel2016-08-261-0/+3
| | | | nxproxy) start-up.
* nxcomp/Loop.cpp: We have GetCopyrightInfo() in Misc.cpp, so why not use it? ↵Mike Gabriel2016-08-241-2/+2
| | | | Also: point to ArcticaProject/nx-libs namespace on Github for further information.
* nxcomp/Loop.cpp: Refer to Github namespace of Arctica Project as location to ↵Mike Gabriel2016-08-241-1/+1
| | | | | | search for software updates. Fixes ArcticaProject/190
* {nx-X11/programs/Xserver/hw/nxagent/{Args.c,Options.{c,h}},nxcomp/{Loop,Misc ↵Mihai Moldovan2016-07-281-1/+2
| | | | }.cpp}: add tolerancechecks parameter as an nx/nx option and ReconnectTolerance as an nxagentOption.
* Per-file copyright notices: Update copyright information in file headers ↵Mike Gabriel2016-07-061-7/+15
| | | | that NoMachine placed there own copyright statement in.
* nxcomp/Loop.cpp: Add Unix file socket support for proxy <-> proxy connection.Mike Gabriel2016-07-041-197/+478
|
* merge code paths depending on acceptHost being ""Salvador Fandino2016-07-041-11/+5
|
* remove now unused function ParseListenOptionSalvador Fandino2016-07-041-20/+0
|
* rewrite WaitForRemote to build on top of ListenConnectionTCPSalvador Fandino2016-07-041-61/+2
|
* remove unused listenHost parameterSalvador Fandino2016-07-041-19/+3
|
* Remove work around for OS/X that was doing nothingSalvador Fandino2016-07-041-24/+0
| | | | | | Remove an old work around that's not needed anymore. Tested on OS/X 10.10 for x86.
* Simplify ParseListenOptionSalvador Fandino2016-07-041-12/+4
| | | | | | Merge code paths. Use GetHostAddress to resolve the target host address instead of inet_aton.
* rewrite SetupUnixSocket to use ListenConnectionUnixSalvador Fandino2016-07-041-70/+20
|
* Rework SetupTcpSocket to use ListenConnectionTCPSalvador Fandino2016-07-041-66/+1
|
* {nx-X11/programs/Xserver/hw/nxagent/{{Args,Handlers,Image,Options}.c,Options ↵Mihai Moldovan2016-06-171-1/+2
| | | | .h},nxcomp/{Loop,Misc}.cpp}: add configurable sleep delay if session is suspended.
* Fix debugging function for Loop.cpp. getDebugSpec was replaced by << operand ↵Nito Martinez2016-05-311-6/+6
| | | | in ChannelEndPoint.{h|cpp}, fixes #130
* display version number in nxcomp log, fixes #127Nito Martinez2016-05-311-2/+0
|
* Provide support for channel endpoints being UNIX file sockets in addition to ↵Salvador Fandino2016-04-271-284/+244
| | | | being TCP/IP sockets.
* Clean up compiler warnings in nxcompFernando Carvajal2016-04-271-10/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit removes several warnings in nxcomp related to unused but set variables. It also replaces tempnam function with the more secure one mkstemp and there has been removed another warning related to setgid and setuid returning values not being checked. So these were the compiler warnings in nxcomp that have been fixed: Loop.cpp: In function ‘int ParseRemoteOptions(char*)’: Loop.cpp:9423:7: warning: variable ‘hasLimit’ set but not used [-Wunused-but-set-variable] int hasLimit = 0; ^ Loop.cpp:9424:7: warning: variable ‘hasRender’ set but not used [-Wunused-but-set-variable] int hasRender = 0; ^ Loop.cpp:9425:7: warning: variable ‘hasTaint’ set but not used [-Wunused-but-set-variable] int hasTaint = 0; ^ Loop.cpp:9427:7: warning: variable ‘hasStrict’ set but not used [-Wunused-but-set-variable] int hasStrict = 0; ^ Loop.cpp:9428:7: warning: variable ‘hasShseg’ set but not used [-Wunused-but-set-variable] int hasShseg = 0; ^ ServerChannel.cpp: In member function ‘virtual int ServerChannel::handleWrite(const unsigned char*, unsigned int)’: ServerChannel.cpp:2132:9: warning: variable ‘hit’ set but not used [-Wunused-but-set-variable] int hit; ^ Proxy.o: In function `Proxy::handleSaveAllStores(char const*) const': Proxy.cpp:(.text+0x2cac): warning: the use of `tempnam' is dangerous, better use `mkstemp' Pipe.cpp: In function ‘FILE* Popen(char* const*, const char*)’: Pipe.cpp:240:23: warning: ignoring return value of ‘int setgid(__gid_t)’, declared with attribute warn_unused_result [-Wunused-result] setgid(getgid()); ^ Pipe.cpp:241:23: warning: ignoring return value of ‘int setuid(__uid_t)’, declared with attribute warn_unused_result [-Wunused-result] setuid(getuid()); ^ There was also a hidden problem in the way Proxy::handleSaveAllStores was checking for an error in the returning value from the call to the virtual method handleSaveAllStores of the specific proxy class really being used (ClientProxy or ServerProxy). Former code was considering the value 0 as the returning value in case of an error whereas both subclasses return the value -1 when there is an error in their handleSaveAllStores method. This bug has been fixed in this commit taking advantage of the modification that was already being made to this method in order to replace tempnam function with the more secure one mkstemp. Fixes: ArcticaProject/nx-libs#103
* Remove compatibility code for nxcomp before 3.5.0Fernando Carvajal2016-04-121-189/+75
| | | | | | | | | | | | | | As a part of nxcomp's clean-up process, compatibility with old protocol versions has been set now at 3.5.0. This commit removes compatibility code from nxcomp so the minimum supported version changes from 1.5.0 (protocol step 6) to 3.5.0 (protocol step 10). At this moment the removal is not complete and it will be followed by some other commits, in order to get rid of several components and files that are no longer used as they were only needed to work with old protocol versions. Refs: ArcticaProject/nx-libs#108
* nxcomp: Make nxcomp/nxproxy aware of nxagent's xinerama option in the ↵Mike Gabriel2015-12-301-1/+2
| | | | $DISPLAY variable.
* nxcomp/Loop.cpp: tiny whitespace fix. No functional change.Mihai Moldovan2015-06-161-1/+1
|
* Fix negotiation in stage 10 errorVadim Troshchinskiy2015-05-201-1/+37
| | | | | Problem fixed by adding a select() call to implement a timeout, and retrying writes if needed.
* This patch allows to cleanup the nxcomp resources to allow for a second ↵Nito Martinez2015-05-151-0/+27
| | | | | | | | | | | | | | | connection inside the same process, instead of a new process as is the nxproxy case. This involves creating a new API call void NXTransCleanupForReconnect(void); which basically cleans up the global state for the connection but does not exit the process. Background ========== This is needed for the IOS platform, where the nxproxy model of forking does not work. Also NX handles most of the errors with an "exit" call which in IOS cannot be easily handled.
* Detection for Mac OS X's launchd service on Mac OS X 10.10 and beyond ↵Mike Gabriel2015-02-131-1/+1
| | | | (607_nxcomp_macosx-X11-launcher-in-private-tmp.full+lite.patch).
* Allow version 4-digit version comparison/handshake ↵Nito Martinez2015-02-131-1/+2
| | | | (400_nxcomp-version.full+lite.patch).
* Force NX proxy to bind to loopback devices only (loopback option) ↵Mike Gabriel2015-02-101-4/+37
| | | | (220_nxproxy_bind-loopback-only.full+lite.patch).
* Fix FTBFS of nxproxy/nxcomp on Android ↵Nito Martinez2015-02-101-4/+8
| | | | (212_nxcomp_build-on-Android.full+lite.patch).
* Set default pack and link options to avoid damage of session ↵Oleksandr Shneyder2015-02-101-4/+4
| | | | (211_nxcomp_set_default_options.full+lite.patch).
* Save session state in file.Oleksandr Shneyder2015-02-101-1/+2
| | | | | | | | | 210_nxagent_save_session_state.full.patch 210_nxcomp_save_session_state.full+lite.patch This patch adds a "state" option to NX (agent) which allows one to specify a file where nxagent will write its session state into.
* Fix BIGENDIAN issue in nxcomp (relevant on PPC64 arch) ↵Mihai Moldovan2015-02-091-2/+2
| | | | (029_nxcomp_ppc64.full+lite.patch)
* Add X11 abstract socket support to nxcomp/nxproxy ↵Mike Gabriel2015-02-091-0/+38
| | | | (027_nxcomp_abstract-X11-socket.full+lite.patch).
* sa_restorer vs. memset (008_nxcomp_sa-restorer.full+lite.patch).Mike Gabriel2015-02-091-19/+4
| | | | | | Use memset instead of setting sa_restorer to NULL. Original-Author: Alexander Morozov
* Revert "release 3.5.0.19"Mike Gabriel2013-03-281-41/+23
| | | | This reverts commit e77bf36d9afbc7e56522574b06217d57c11dd095.
* release 3.5.0.19Mike Gabriel2013-03-281-23/+41
|
* Imported nxcomp-3.4.0-7.tar.gznxcomp/3.4.0-7Reinhard Tartler2011-11-131-1/+8
| | | | | | | | Summary: Imported nxcomp-3.4.0-7.tar.gz Keywords: Imported nxcomp-3.4.0-7.tar.gz into Git repository
* Imported nxcomp-3.4.0-6.tar.gznxcomp/3.4.0-6Reinhard Tartler2011-11-131-16/+16
| | | | | | | | Summary: Imported nxcomp-3.4.0-6.tar.gz Keywords: Imported nxcomp-3.4.0-6.tar.gz into Git repository
* Imported nxcomp-3.4.0-1.tar.gznxcomp/3.4.0-1Reinhard Tartler2011-11-131-2/+2
| | | | | | | | Summary: Imported nxcomp-3.4.0-1.tar.gz Keywords: Imported nxcomp-3.4.0-1.tar.gz into Git repository
* Imported nxcomp-3.2.0-7.tar.gznxcomp/3.2.0-7Reinhard Tartler2011-11-131-1/+2
| | | | | | | | Summary: Imported nxcomp-3.2.0-7.tar.gz Keywords: Imported nxcomp-3.2.0-7.tar.gz into Git repository
* Imported nxcomp-3.2.0-6.tar.gznxcomp/3.2.0-6Reinhard Tartler2011-11-131-3/+156
| | | | | | | | Summary: Imported nxcomp-3.2.0-6.tar.gz Keywords: Imported nxcomp-3.2.0-6.tar.gz into Git repository