Major restructuring of how streams work. Neither input nor output
streams are now blocking. This avoids stalling the rest of the client or
server when a peer is slow or unresponsive.
Note that this puts an extra burden on users of streams to make sure
they are allowed to do their work once the underlying transports are
ready (e.g. monitoring fds).
We now filter incoming data, which means we can start assuming the
clipboard data is always null terminated. This allows us to clean
up a lot of the internal handling.
Move computeScreenLayout/setScreenLayout to unixcommon lib
These two code blocks are not specific to Xvnc/vnc.so, but useful for
x0vncserver as well. RandrGlue.h defines the interface on which
unixcommon depends on.
No longer tolerate loading the VNC extension but not being able to
initialize it. This avoids a lot of error prone checking to see
if the extension has started fully or not.
Handle the clipboard directly in the server, avoiding the
dependency on vncconfig. This commit adds support for clipboard
from the client to the server. Handling of the other direction
will follow.
Fix race problem with detecting listening inetd sockets
The previous detection would fail if the socket closed before we
had time to inspect it, which got us stuck in a loop as we would
try (and fail) to do accept() on a non-listening socket.
Fix race problem with detecting listening inetd sockets
The previous detection would fail if the socket closed before we
had time to inspect it, which got us stuck in a loop as we would
try (and fail) to do accept() on a non-listening socket.
It is easier to control object life time and avoid magical socket
duplication by having a single TcpListener object to pass around.
We have to be more careful about deleting the object though.
Refuse to start Xvnc if we failed to initialise a screen
Starting Xvnc without having any VNC functionality is pretty much
pointless. So terminate when that happens, making the situation easier
to detect for startup scripts.
The TcpListener constructor now takes a 'struct sockaddr*' instead of
a string, and the createTcpListeners function creates TcpListener
instances for an address based on the results from getaddrinfo().
The XserverDesktop class now takes a list of TcpListener instances for
each of the RFB and HTTP sockets.
The TcpListener::closeFd member variable is not used and has been
removed.
Restructure Xvnc/libvnc.so code to avoid C++ header hacks
The internal Xorg headers are very incompatible with C++ and we've had
to resort to all kinds of hacks in order to include them in our C++
code. This approach isn't really viable long term so restructure things
so that we have a glue layer written in C that bridges the Xorg core
with the RFB classes.
Gets rid of a loooot of code and complexity.
Colour map clients are still supported through an
automatically generated map, but we lose the ability to
develop a client or server that uses colour maps
internally.
Fix bad size calculation in GetQueryConnect handler as well
as an endian conversion fix. Patch by Christian Steinle.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@5124 3789f03b-4d11-0410-bbf8-ca57d06f2519
Make socket writes non-blockable. This allows the system to more quickly
return back to the Xorg main loop, meaning that things will be more responsive
in the presence of slow VNC clients.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4735 3789f03b-4d11-0410-bbf8-ca57d06f2519
[Development] Allow to modify only "desktop", "SendCutText" and "AcceptCutText"
Xvnc's parameters via vncconfig.
Also Xvnc got new option called "-noclipboard" which disables "*CutText"
runtime modification.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@4226 3789f03b-4d11-0410-bbf8-ca57d06f2519
We forgot to update the internal variables with the previous version which
caused problems with some clients (first noticed with gtk-vnc).
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3746 3789f03b-4d11-0410-bbf8-ca57d06f2519
Based on patch by George Wright but heavily rewritten in order to
dynamically reallocate the framebuffer, allowing any resize.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3688 3789f03b-4d11-0410-bbf8-ca57d06f2519
Implemented support for DesktopName pseudo encoding, which allows
updating the desktop name on the fly.
Tested in ThinLinc since 2008-01-07.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@3549 3789f03b-4d11-0410-bbf8-ca57d06f2519
Use SelectionCallback to handle selection changes. They should never
be touched directly and they have been converted to linear list
instead array.
git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/branches/1.5-xserver@2451 3789f03b-4d11-0410-bbf8-ca57d06f2519