aboutsummaryrefslogtreecommitdiff
path: root/nxcomp
Commit message (Collapse)AuthorAgeFilesLines
* nxcomp/test/logging_test.cpp: return a value in non-void function.Mihai Moldovan2017-12-151-0/+2
| | | | Failed *SUSE checks.
* nxcomp/Makefile.am: call aclocal with the correct include dir argument.Mihai Moldovan2017-12-151-0/+2
|
* nxcomp/src/Log.cpp: only create a new queue entry if we actually intend to ↵Mihai Moldovan2017-12-111-3/+3
| | | | | | write it out later. Fixes: ArcticaProject/nx-libs#596
* Silence warning: "ar: 'u' modifier ignored since 'D' is the default"Ulrich Sibiller2017-12-111-0/+3
| | | | Fixes ArcticaProject/nx-libs#530
* nxcomp: fix shadow warningUlrich Sibiller2017-12-111-2/+2
| | | | | | | | | | | | | | Fixes this: CXX Loop.lo Loop.cpp: In function 'void handleCheckResultInLoop(int&, int&, int&, fd_set&, fd_set&, timeval&, timeval&)': Loop.cpp:14080:68: warning: declaration of 'startTs' shadows a global declaration [-Wshadow] struct timeval &startTs) ^ Loop.cpp:1020:13: note: shadowed declaration is here T_timestamp startTs; Fixes ArcticaProject/nx-libs#545
* nxcomp: use new macro SAFE_FREE(ptr)Ulrich Sibiller2017-12-094-39/+33
| | | | | Should be used instead of free() calls and will clear the pointer after calling free(). This can prevent double-free or use-after-free errors.
* Loop.cpp: fix more memory leaksUlrich Sibiller2017-12-091-1/+15
| | | | | | | The thread specific stringstream objects on the stack need to be deleted, not just pop()ed. Fixes ArcticaProject/nx-libs#573 (partially)
* Loop.cpp: fix two memleaksUlrich Sibiller2017-12-091-4/+19
|
* ChannelEndPoint.cpp: fix two memleaksUlrich Sibiller2017-12-091-4/+10
|
* nxcomp: simplify free callsUlrich Sibiller2017-12-091-3/+3
| | | | free() can handle NULL itself
* nxcomp: fix double freeUlrich Sibiller2017-12-091-0/+2
| | | | Fixes ArcticaProject/nx-libs#569
* nxproxy/nxcomp: document logging optionsUlrich Sibiller2017-12-071-0/+14
|
* nxcomp/nxproxy: slightly improve the usage message of nxproxyUlrich Sibiller2017-12-071-6/+8
|
* nxcomp/nxproxy: add missing hint for keyconv optionUlrich Sibiller2017-12-071-0/+1
|
* nxcomp: use lowercase abbreviations for seconds and millisecondsUlrich Sibiller2017-12-029-71/+71
|
* nxcomp: remove unused return valuesUlrich Sibiller2017-12-021-19/+12
| | | | Some functions' return values are never used anywhere, so drop them.
* nxcomp: Fix setting of global tcpFDUlrich Sibiller2017-12-021-1/+2
| | | | | | | This corrects a flaw that stayed undetected for 2.5 years, introduced via c5a2cf82f6baf7a9e64ec2328a5bac0dfee453ef Fixes ArcticaProject/nx-libs#573
* nxcomp/src/Misc.cpp: Update explanation for the NX_TEMP env variable.Mike Gabriel2017-11-221-2/+1
|
* nxcomp/src/Loop.cpp: hardcode X11 and (legacy/xfs) font UNIX paths.Mihai Moldovan2017-11-041-15/+7
| | | | | | | | Fixes: ArcticaProject/nx-libs#536 Allowing overrides via NX_TEMP and TEMP breaks system using pam_tmpdir.so and most server infrastructure expects the location to be fixed anyway.
* nxcomp/src/Auth.cpp: handle launchd sockets in DISPLAY variable correctly ↵Mihai Moldovan2017-11-031-3/+23
| | | | when fetching X cookie.
* nxcomp/m4/ax_pthread.m4: move to top-level m4/ directory, use symlink.Mihai Moldovan2017-10-271-485/+1
|
* Regression fix for f855b3b6. Caused FTBFS with Loop.cpp:2669:0: error: ↵Mike Gabriel2017-10-271-1/+0
| | | | unterminated #ifdef (#ifdef TIME).
* nxcomp/src/Loop.cpp: fix whitespace errors on continued lines.Mihai Moldovan2017-10-271-810/+810
|
* Remove leading \n in NXTrans* loggingVadim Troshchinskiy2017-10-271-3/+3
|
* Fix whitespace and line splitting issues reported by ionicVadim Troshchinskiy2017-10-271-10/+19
|
* Conversion of Loop.cpp to the new log systemVadim Troshchinskiy2017-10-271-2560/+1285
|
* nxcomp: add basic logging_test utility in test subdirectory.Mihai Moldovan2017-10-276-1/+373
| | | | Needs more sophisticated features to actually test stuff correctly.
* nxcomp/src/Log.h: prepare for logger testing application.Mihai Moldovan2017-10-271-0/+4
| | | | DO NOT USE!
* nxcomp/src/Log.cpp: add PID to thread ID output if requested.Mihai Moldovan2017-10-271-1/+2
| | | | | | | | The default function we use (if a thread name is not specified explicitly) is pthread_self(). This function returns a number that is guaranteed to be unique for each thread within a process, but this assertion doesn't hold globally. Hence only using the thread ID is ambiguous when logging from multiple processes.
* nxcomp/src/Log.h: block signals while writing out data.Mihai Moldovan2017-10-271-0/+20
| | | | | Prevents race conditions caused by signal handlers while flushing out our log queue.
* nxcomp/src/Log.{cpp,h}: port to std::stack as internal buffer structure.Mihai Moldovan2017-10-272-23/+37
| | | | | | | | This has one drawback: after flushing log data to its underlying output, a new NXLogStamp object MUST be written to the NXLog object in order to create a new entry within the stack. This can be changed if necessary. For now I'd like to keep it as-is.
* nxcomp/{configure.ac,Log.cpp}: implement configure-time std::put_time check ↵Mihai Moldovan2017-10-272-1/+19
| | | | and use macro value in Log.cpp.
* nxcomp/Log.h: delete stream_ member before class object destruction.Mihai Moldovan2017-10-271-0/+4
|
* nxcomp/Log.h: also clear the buffer after setting it to an empty string.Mihai Moldovan2017-10-271-1/+2
|
* Set default log level to WARNINGVadim Troshchinskiy2017-10-271-1/+1
| | | | | This is to ensure the log output is the same as previous releases, which didn't have INFO defined by default.
* New logging implementationVadim Troshchinskiy2017-10-274-0/+719
| | | | | | | | Features: * Works without ifdefs * Configurable with commandline arguments * Log level configurable per file * Thread safe
* nxcomp: add AX_PTHREAD code from autoconf-archive and check for pthread support.Mihai Moldovan2017-10-273-1/+494
|
* nx{comp{,shad},proxy}: add configure flag --enable-cxx11 to enable and setup ↵Mihai Moldovan2017-10-273-0/+8
| | | | | | | | | | optional C++11 support. Use AX_CXX_COMPILE_STDCXX(_11) from autotools archive. Note: should only be used in tandem. Make sure that each component either uses the C++11 ABI or none uses it. Mixing and matching libraries and binaries with different C++ ABIs might lead to weird errors.
* nxcomp/configure.ac: rename --{en,dis}able-info to --{en,dis}able-debug, as ↵Mihai Moldovan2017-10-271-1/+1
| | | | originally planned.
* Fix bug #525: PANIC! No port specified for multimedia connectionsVadim Troshchinskiy2017-10-103-11/+19
| | | | | | | Commit 5f1eb0dc3eb89e84a3b146975e147b995fb7673f introduced a regression that made the use of the multimedia port mandatory. Fixes ArcticaProject/nx-libs#525
* nxcomp/src/Loop.cpp: Reduce control->TokenSize slightly again in order to ↵Simon Matter2017-10-091-2/+2
| | | | fix fragmentation of packages when on VPN (or otherwise encapsulated) connections.
* .gitignore: Improve all .gitignore files, adapt to autotools build-flow and ↵Mike Gabriel2017-10-091-2/+0
| | | | its build cruft.
* nxcomp/src/Loop.cpp: whitespace fixes only.Mihai Moldovan2017-09-291-6/+6
|
* nxcomp/configure.ac: prettify AC_ARG_ENABLE() calls, use more quotes and ↵Mihai Moldovan2017-09-291-13/+13
| | | | AS_IF() where appropriate.
* Fix nxagent argument parsing logicVadim Troshchinskiy2017-09-292-57/+51
| | | | | | | | | This makes it so that slave=1 works again as it should. The changes introduced earlier resulted in the unintentional requirement to specify the actual port number, breaking backwards compatibility. Fixes: ArcticaProject/nx-libs#518
* nxcomp/src/{Loop,Proxy}.cpp: On Debian/kFreeBSD (and other *BSD variants) ↵Mike Gabriel2017-09-062-0/+16
| | | | | | the sockaddr_un.sun_path property is 104 chars long, not 108. Hard-coding Unix domain sockets in nxcomp the string length 104. Fixes ArcticaProject/nx-libs#507.
* nx*/configure.ac: Use newly introduced macro NX_DEFAULT_OPTIONS instead of ↵Mike Gabriel2017-08-111-1/+1
| | | | NX_COMPILER_FLAGS.
* nxcomp/configure.ac: fix copy-and-paste typo (nxcompshad.pc.)Mihai Moldovan2017-08-091-1/+1
|
* nxcomp/configure.ac: we don't need to specify empty optional parameters.Mihai Moldovan2017-08-091-2/+2
|
* nxcomp/configure.ac: Don't rely on pkg-config alone when it comes to testing ↵Mike Gabriel2017-08-081-4/+4
| | | | | | | | | | for presence of libjpeg shared lib and header files. Especially systems still using the IJG libjpeg implementation are likely to lack the libjpeg.pc file. . So this adds some alternative way of detecting if all libjpeg related build-dependencies are in place.