Catch IOException when trying to copy the document and send error message.
Otherwise, the exception will just propagate up to handleRequest() and the
connection will be silently closed. Closing the connection is fine as such, I
think, but we need to send an error message first.
Currently we require the current version, 1.6.0, and as soon as 1.6.1 is out,
I will start requiring that, because I want to use a feature I submitted to
it.
Surround most of configure.ac with AC_LANG_PUSH([C++]) while at it, as this is
all C++ code anyway.
Otherwise, if we use the same port number and same HTTPServer, if enough
clients try to contact us and, we won't be able to accept child processes
having been spawned.
Also add some temporary debugging output here and there to debug lifecycle
management issues.
Just a stopgap measure so far. Clearly will need some logic to get rid of too
many children if they are just hanging around with no clients incoming. Also,
we need some sanity check not to spawn an unlimited number of children.
We don't actually need this plugin because the server
dictates how the selection will work.
Will remove the whole plugin when I'm sure this won't have other
applications
Otherwise two or more linkOrCopy() functions running simultaneously will lead
to a mess.
Actually nftw() is not guaranteed to be thread-safe, I think, so we should
really use something that is, like Poco's SimpleRecursiveDirectoryIterator.
It probably is not a good idea to keep depleting the entropy source needlessly
by having a separate RNG in the preSpawn(). Use just one shared RNG and
protect access to it with a mutex.
Use setuid root otherwise. (But note that the portablity to other
Unixes is a work in progress, and for instance it is known that this
doesn't work on OS X yet.)
The document is centered by setting map's maxBounds
There are 2 types of scroll events:
- one generated during scrolling which actually pan's the map
- one generated when scrolling stops, this is used to keep track of
scrolling events
When the document is zoomed, the scrollbars are placed at the right
offset as the document's dimension changes and this is done with
the scrollTo method after temporarily disabling the event listener.
Added scrollContainer - the div that will get scrollbars
mockDoc - a mock document div of size equal to the document's, which
will cause the appearance of scrollbars
The size of the map now equals the visible area, so I've restored
the methods to work on this new size