Commit Graph

22 Commits

Author SHA1 Message Date
Benjamin Barenblat 05c7aceb1e Fix up clang-formatting a bit
Move some characters around to optimize clang-format output.
2023-08-07 22:03:00 -04:00
Benjamin Barenblat 3acaa1c4d3 clang-format Mosh
Run clang-format over the Mosh source tree. This is a large change and
has been factored into its own commit for auditability. Reproduce it
with

    find . -name \*.cc -or -name \*.h | while read f; do clang-format -i --style=file $f; done
2023-08-07 22:03:00 -04:00
Alex Chernyakhovsky cf542739cc Switch to C++ versions of standard C headers 2023-07-30 19:02:51 -04:00
Alex Chernyakhovsky 325098ac07 Switch to fully-qualified #include
Previously, mosh used extensive -I flags and all of the mosh-local
makes it really hard to tell what the proper dependency graph is, so
instead remove the -I arguments in favvor of $(top_srcdir) and qualify
the paths wherever they are used.
2023-07-30 17:03:40 -04:00
Anders Kaseorg 10dca75fb2 Type Select::got_signal as volatile sig_atomic_t
Fixes #634.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2018-01-18 19:25:05 -05:00
John Hood 9ffbeddbc8 Put spin debug under -vv flag, and add to mosh-client 2016-11-06 06:15:41 -05:00
John Hood f89f1da0b5 Log/limit pselect() with timeout of 0
This is not a fix for bad timeouts, but rather a band-aid
to keep Mosh from consuming large amounts of CPU time.
2016-11-06 06:15:41 -05:00
John Hood 6b71351138 select.h: workaround and report Cygwin select() bug
Resolves #705.
2016-01-11 04:37:35 -05:00
John Hood ca21788c96 Remove usage of exceptional fdsets with select(). 2016-01-11 04:35:21 -05:00
John Hood b742e958b6 mosh-server: Support timeouts on lost connectivity to network client.
Closes #690.
2015-11-24 02:36:08 -05:00
John Hood 026a3f0346 Resolve cppcheck issues.
Signed-off-by: John Hood <cgull@glup.org>
2015-06-10 23:50:56 -04:00
Jérémie Courrèges-Anglas 24b078a5a1 workaround for systems not providing pselect
using a mix of good old select and sigprocmask

Signed-off-by: Jérémie Courrèges-Anglas <jca@wxcvbn.org>
2013-04-16 11:09:42 +02:00
Keith Winstein d17fb7824b Reset fd sets every time we poll (because network.fd() can now change) 2012-10-05 00:06:37 -04:00
Keith Winstein 50e75b3127 Make sure we're not querying fds that we never polled for in the first place 2012-10-04 23:53:34 -04:00
Keith Winstein a744004bf6 Get system timestamp less often (only after sleeping/selecting) 2012-07-26 21:13:26 -04:00
Keith Winstein 92ecb99b71 Add OpenSSL licensing exception 2012-07-20 16:46:00 -04:00
Keith Winstein 5e86700a0a Fix OS X 10.5 problem where FD_ISSET() argument isn't const 2012-05-23 03:19:36 -04:00
Keith Winstein a4dd2fed89 Use static local variable for consistency with compressor, dispatch table 2012-05-16 00:17:37 -04:00
Keegan McAllister 1d0b16881c Switch to pselect(2) and add signal handling to Select class 2012-05-16 00:00:27 -04:00
Keegan McAllister 7fc1aa30a5 Move dummy_fd_set into Select
Now that we have select.cc.
2012-05-16 00:00:27 -04:00
Keegan McAllister 768d4ce797 Make Select a singleton
It's going to manipulate process-global signal state, so multiple
instances do not make sense.
2012-05-16 00:00:27 -04:00
Keegan McAllister 0019b9d92a Add a convenience wrapper for select(2) 2012-05-16 00:00:27 -04:00