aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* Use "static" for helper functionsPierre Ossman2024-06-242-3/+3
| | | | | These functions act only on the input parameters, so let's make them static to more clearly indicate that they do not act upon any object.
* Simplify RandR output name handlingPierre Ossman2024-06-241-36/+26
| | | | | Store the name in a std::string to make things less complex as we don't need to be as careful about making sure the data is free():d.
* Avoid redundant argumentsPierre Ossman2024-06-246-50/+48
| | | | | Remove redundant arguments where the method already has access to the relevant variable as an object attribute.
* Simplify code using range-based for loopsPierre Ossman2024-06-2413-118/+82
| | | | | | | | | These are often more readable as they avoid a lot of the boilerplate of iterating over fixed arrays or STL containers. Note that this change is very conservative to avoid noise in "git blame". Only loops where this is a clear improvement have been converted.
* Remove careful client iteratationPierre Ossman2024-06-241-42/+24
| | | | | | | Clients cannot remove themselves from the list as we are iterating, so we don't need this complexity. If a client encounters a problem, it will only mark it self as closed and will be removed from the list at a later time.
* Prefer std::find() over manual searchPierre Ossman2024-06-246-53/+39
| | | | | Let's avoid reimplementing something basic that's available in the standard library. It also makes the code easier to read.
* Remove unnecessary headers from Security.cxxPierre Ossman2024-06-241-18/+1
|
* Enforce using "override"Pierre Ossman2024-06-241-0/+1
| | | | Make sure developers don't miss marking methods correctly.
* Mark overridden virtual functionsPierre Ossman2024-06-24124-527/+534
| | | | | Use the new "override" keyword to properly differentiate between new virtual methods, and existing virtual methods being overridden.
* Enforce using nullptr for C++ codePierre Ossman2024-06-241-0/+1
| | | | | The compiler can help out in making sure we are consistent in our use of nullptr rather than NULL.
* Disable gcc NULL warning for context menuPierre Ossman2024-06-241-1/+4
| | | | | | We use the pointer to just store an identifier for the menu, but this is enough for gcc to think we are using 0 instead of nullptr and complain. Even an explicit cast isn't enough to silence it here for some reason.
* Use nullptr in all C++ codePierre Ossman2024-06-24185-938/+979
| | | | | It's more readable than 0, and a bit safer than NULL, so let's try to follow modern norms.
* Make sure we use C++ 11Pierre Ossman2024-06-242-1/+4
| | | | | | It's rare we use a compiler that has anything older as a default, but it does happen sometimes. So make sure to guarantee this so we can start using more modern constructs.
* Fix Windows installer dependenciesPierre Ossman2024-06-241-2/+2
| | | | | Make sure the dependencies point to the correct files, even if an out of tree build is used.
* Merge pull request #1767 from bphinz/ubuntu-nobleBrian Hinz2024-06-1922-73/+865
|\ | | | | Updates for package builds
| * Remove support for EoL operating systemsBrian P. Hinz2024-06-1918-929/+0
| |
| * Ubuntu packaging updatesBrian P. Hinz2024-06-1922-25/+866
| |
* | Merge branch 'xserver-cleanup' of github.com:CendioOssman/tigervncPierre Ossman2024-06-1930-1507/+32
|\ \
| * | Remove old Xorg configure argumentsPierre Ossman2024-06-193-9/+0
| | | | | | | | | | | | These are no longer used in the versions of Xorg currently in use.
| * | Raise Xorg requirement to 1.20+Pierre Ossman2024-06-195-338/+1
| | | | | | | | | | | | | | | No current distribution uses anything older, so let's make things easier for us to maintain.
| * | Remove Ubuntu 18.04 packagingPierre Ossman2024-06-1916-880/+0
| | | | | | | | | | | | | | | Ubuntu 18.04 has been EOL for almost a year, so remove those packages so we can ease our maintenance burden.
| * | Avoid patching miinitext.c for XvncPierre Ossman2024-06-198-150/+12
| | | | | | | | | | | | | | | | | | Things do not need to be this complicated. We can make sure the VNC extension is always included in a much cleaner way, at least since Xorg 1.16.
| * | Stop explicitly including fbcmap_mi.cPierre Ossman2024-06-191-1/+1
| | | | | | | | | | | | This hasn't been needed since Xorg 1.16.
| * | Stop linking to libX11Pierre Ossman2024-06-191-1/+1
| | | | | | | | | | | | | | | Unclear why this was ever needed. libX11 is for X11 clients, and we're building a server.
| * | Clean up CPPFLAGS handling in xserverPierre Ossman2024-06-197-30/+17
| | | | | | | | | | | | | | | Make things a bit easier to maintain. This style is also more in line with what is being done for other DDX.
| * | Remove unused NO_MODULE_EXTS definePierre Ossman2024-06-191-1/+1
| | | | | | | | | | | | This has never actually been used, as far as I can tell.
| * | Actually use config.h in Xvnc/libvnc.soPierre Ossman2024-06-191-3/+6
| | | | | | | | | | | | | | | Rather than disabling this, make sure the build can find the relevant file.
| * | Simplify Xorg version handlingPierre Ossman2024-06-1910-111/+10
| | | | | | | | | | | | | | | VENDOR_RELEASE has been available as a #define since Xorg 1.7, so let's use that and remove all of our custom magic.
* | | Merge branch 'present' of github.com:CendioOssman/tigervncPierre Ossman2024-06-1936-170/+419
|\| | | |/ |/|
| * Slow down fake clock when no clientsPierre Ossman2024-06-191-11/+32
| | | | | | | | | | | | | | | | | | | | Run the frame clock at a slow 1 Hz if there are no clients connected. This is similar to what a normal X server does when the screen is blanked, and should keep applications waiting for the frame tick happy. Note that we still only keep the frame clock running if there is any application that are interested in it. Otherwise we still stop it completely.
| * Keep frame clock running if waiting for frame tickPierre Ossman2024-06-194-5/+20
| | | | | | | | | | | | | | | | | | | | | | If there is something interested in synchronizing to a frame tick, then keep the frame clock running, even if there are no updates. This is need mainly when something starts rendering, but also when something renders much slower than the frame clock (so it is essentially constantly "starting"). Such an application will not draw anything until it gets a new frame tick, which it won't get as the frame clock is waiting for something to start drawing.
| * Restart the frame timer immediatelyPierre Ossman2024-06-191-3/+3
| | | | | | | | | | | | This marks the timer as started again, before we call out to various external places that might be confused by the frame timer reporting that it is stopped.
| * Add support for X Present extensionPierre Ossman2024-06-1912-8/+218
| | | | | | | | | | | | | | This makes it possible for applications to synchronize their updates to the updates sent out to clients. This avoids tearing, and could in the future also help with rate limiting applications to what the client can actually show.
| * Add missing ErrorF() newlinesPierre Ossman2024-06-191-3/+3
| |
| * Make SDesktop::start()/stop() optionalPierre Ossman2024-06-193-18/+2
| | | | | | | | | | Let's avoid requring these as a desktop implementation can now set up everything in the init() method.
| * Maintain a constant VNCServer/SDesktop connectionPierre Ossman2024-06-198-22/+37
| | | | | | | | | | | | | | | | | | The desktop isn't completely paused just because there are no clients, so it might still need some support from the server object. This is primarily an issue for headless servers, where they need to continue emulating things even without clients. A scraping server can generally go completely passive if there are no clients.
| * Make it easier to change timer intervalPierre Ossman2024-06-193-6/+8
| |
| * Explicitly request timer repetitionPierre Ossman2024-06-1918-73/+63
| | | | | | | | | | | | One-shot timers are more common, so let's change the API a bit to make that use case simpler. This API also makes it more clear what is happening.
| * Fix up Timer commentsPierre Ossman2024-06-191-27/+34
| | | | | | | | They were badly formatted, way longer than the normal 72 columns.
| * Add safety check to getNextTimeout()Pierre Ossman2024-06-191-0/+6
| | | | | | | | | | | | It currently won't ever be called with an empty list of timers, but it is a public function so that might happen in the future. Make sure this case is handled without crashes.
| * Stop treating "0" as "no timeouts"Pierre Ossman2024-06-198-23/+18
| | | | | | | | | | It is much more sane to treat "0" as "a timer is ready NOW", so let's change to using -1 as the invalid timeout value.
| * Remove unneeded iterationPierre Ossman2024-06-191-3/+1
| | | | | | | | This should have been done in a4308c9.
| * Detect conflicting timer reschedulingPierre Ossman2024-06-191-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Repeating a timer can be done in two ways: * Returning true from the handler * Calling start() again in the handler The latter is useful if you want to change the timer interval. If both are used, then it becomes ambiguous when the timer should fire again. Detect this case and warn about it. Current implementation will respect the new interval given to start(), rather than the interval set before running the handler.
* | Add support for PKCS11 jar signingBrian P. Hinz2024-06-152-10/+37
| |
* | Merge branch 'pam_env' of github.com:CendioOssman/tigervncPierre Ossman2024-05-309-84/+134
|\ \
| * | Create common recursive mkdir()Pierre Ossman2024-05-305-65/+87
| | | | | | | | | | | | | | | | | | | | | Avoid duplicating this complexity in too many places. At the same time make the interface more identical to regular mkdir(), for familiarity.
| * | Use $XDG_STATE_HOME for known hosts storagePierre Ossman2024-05-303-4/+8
| | | | | | | | | | | | | | | This is an often changed database, so it is better suited for $XDG_STATE_HOME rather than the more static $XDG_DATA_HOME.
| * | Only do restorecon() for legacy directoryPierre Ossman2024-05-301-12/+12
| | | | | | | | | | | | | | | This is only needed because of an historical type change of the legacy directory, so avoid doing it anywhere else.
| * | Fix late vncsession loggingPierre Ossman2024-05-301-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | The syslog file descriptor will be closed when we are cleaning up in preparation for running the vncserver script, so we need to explicitly reopen things in case we need to log errors. At the same time, try to be polite and explicitly close the log when appropriate.
| * | Respect PAM modules for $XDG_STATE_HOMEPierre Ossman2024-05-301-3/+16
| | | | | | | | | | | | | | | E.g. pam_env.so might modify this variable, so we should see what we get out of PAM when building a log file path.