Commit Graph

1389 Commits

Author SHA1 Message Date
john hood f3073bbe5d Add git commit version info 2015-05-25 03:46:48 -04:00
john hood e0138bdb2b Better document mosh envars and escape-key machinery. 2015-05-25 03:41:31 -04:00
Geoffrey Thomas 2ea844e54a .gitignore: Add compile and test-driver (from autogen.sh) 2015-05-25 02:40:51 -04:00
Anders Kaseorg af720b41e1 configure.ac: Intentionally underquote m4_normalize calls
This works around a bug in Autoconf 2.64 and earlier, which generated
ridiculous symbols like
  /* #undef HAVE_M4_NORMALIZE___FCNTL_H__LANGINFO_H__LIMITS_H__… */
instead of the ones we need.  It was fixed by v2.65~21:
  http://git.savannah.gnu.org/gitweb/?p=autoconf.git;a=commitdiff;h=81c80d1bf6c8ddf732d0b89f6fc5e306dac9705e

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2015-05-25 02:24:12 -04:00
Anton Lundin 3f38a10a2e Implement CTTY grabbing when TIOCSCTTY is missing
AIX is missing TIOCSCTTY, so we assign us a ctty via a open of the slave
device.

Signed-off-by: Anton Lundin <glance@acc.umu.se>
2015-05-25 02:22:21 -04:00
John Hood 814a2ae55d clang/arm fixup for FreeBSD-CURRENT 2015-05-25 02:17:25 -04:00
john hood 060061aa21 Fix forkpty() for FreeBSD 10. 2015-05-25 02:17:24 -04:00
John Hood 30c09b4613 Comply with new C++11 token pasting rules 2015-05-25 02:17:24 -04:00
John Hood fdf8e427c3 OpenBSD: Use snprintf, not sprintf (PORT) 2015-05-25 02:17:24 -04:00
Anders Kaseorg e52d22b6da Timestamp: Prevent integer overflow on Darwin PPC 32-bit
A Darwin PPC 32-bit user observes huge values numer == 1000000000 and
denom == 18431683 returned from mach_timebase_info().  For these
values, mach_absolute_time() * numer overflows uint64_t every 1000.82
seconds, and 1000000 * denom always overflows uint32_t, with the
effect of making time run backwards at -11190660 times its usual
speed.

This bug was masked on Darwin x86 64-bit, where numer == denom == 1.

Fix it by doing the conversion with double arithmetic instead.

Closes #479.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2015-05-25 02:14:53 -04:00
cgull cfc29387ae Merge pull request #581 from tigeli/master
ocb: fix gcc4.8 compiling problem with __ARM_NEON__
2015-05-21 01:31:31 -04:00
cgull 78134f20d4 Merge pull request #514 from rpwoodbu/mosh-nacl
Conditionally rename main to mosh_main for building under NaCl.
2015-05-21 01:29:44 -04:00
Pasi Sjöholm ff84425885 ocb: fix gcc4.8 compiling problem with __ARM_NEON__
Fixes following problem when compiling mosh with gcc4.8 and
__ARM_NEON__ defined by using -121 instead of 135.

ocb.cc: In function 'block double_block(block)':
ocb.cc:263:56: error: narrowing conversion of '135' from
'int' to '__builtin_neon_qi' inside { } is ill-formed in
C++11 [-Werror=narrowing]

Signed-off-by: Pasi Sjöholm <pasi.sjoholm@jollamobile.com>
2015-02-03 11:21:46 +02:00
Keith Winstein c6cd99ba97 terminalfunctions.cc: Refactor out set_if_available() 2014-12-15 21:04:08 -08:00
Andrew Chin e115f05f0d Clear other mouse modes if 1000 or 1002 are set
I'm not sure if this is correct, but tmux does this!

Signed-off-by: Andrew Chin <achin@eminence32.net>
2014-12-15 20:55:28 -08:00
Andrew Chin 0be97a80bd Implement UTF8 mouse mode (SET_EXT_MODE_MOUSE DECSET 1005)
Signed-off-by: Andrew Chin <achin@eminence32.net>
2014-12-08 20:41:11 -05:00
Andrew Chin 94a35958c2 Revert bb36933472
We aren't sure why this change was made, and reverting it appears to help
fix mouse issues in emacs related to text hilighting.

Signed-off-by: Andrew Chin <achin@eminence32.net>
2014-12-08 20:40:38 -05:00
Richard Woodbury cd1317b273 Conditionally rename main to mosh_main for building under NaCl. 2014-04-26 20:50:01 +00:00
Anders Kaseorg 50152bfcba mosh-client: Catch all exceptions when ensuring client is shut down
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2014-01-08 18:54:40 -05:00
Anders Kaseorg 56837881fc Fix MOSH_ESCAPE_KEY validation
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2014-01-08 18:52:08 -05:00
Anders Kaseorg 7c942e6836 Connection::try_bind: Pass port argument 0 as a string
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2014-01-04 04:31:30 -05:00
Anders Kaseorg b39da20edc AddrInfo: Fix error message generation when node == NULL
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2014-01-04 04:31:30 -05:00
Anders Kaseorg 5532117984 Revert "Fix mosh-server segfault on startup when run without arguments"
This reverts commit 578db45fbf.

The NULL inputs to getaddrinfo are valid in certain cases, and at
least in the case of node, important.  The segfault happens not with
getaddrinfo, but with the error message generation below it.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2014-01-04 04:31:02 -05:00
Keith Winstein 578db45fbf Fix mosh-server segfault on startup when run without arguments 2014-01-04 03:08:57 -05:00
Igor Bukanov 96bf5af1b4 mosh-server: allow startup with PTY with zero width or height like Emacs shell.
Closes #472
Closes #473
2014-01-04 02:55:17 -05:00
Keith Winstein 27678941d4 network.cc: Properly close old fd on Socket assignment operator
Fix thanks to Igor Bukanov. Closes #470.
2014-01-04 02:51:37 -05:00
Bazyli Brzóska 492cfa3449 Implement vt100 mouse mode (1000)
(closes #461)
2014-01-04 02:42:26 -05:00
Bazyli Brzóska bb36933472 xterm extended fix 2014-01-04 02:42:15 -05:00
Bazyli Brzóska 926bbcc746 Implement xterm extended mouse mode 2014-01-04 02:42:15 -05:00
Bazyli Brzóska 5ef7f43479 Implement xterm mouse mode 2014-01-04 02:42:15 -05:00
Anders Kaseorg 6f0669b909 debian/control: Recommend IO::Socket::IP
This is optional, but needed for IPv6 support.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2013-08-17 09:21:38 -04:00
Anders Kaseorg a4c5829812 scripts/mosh: Add -6 option to connect with IPv6
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2013-08-17 09:21:38 -04:00
Anders Kaseorg aeee659c28 scripts/mosh: Let IO::Socket resolve the hostname
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2013-08-17 09:02:45 -04:00
Anders Kaseorg 553918d3f2 Connection: Support IPv6 addresses
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2013-08-17 09:02:44 -04:00
Anders Kaseorg 110cce3773 Connection: Move socket creation out of setup
Once we support IPv6, we won’t be able to create a socket until we
know which address family to use.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2013-08-17 08:58:16 -04:00
Anders Kaseorg c1f96b37a1 Connection: Store the port number as a string
Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2013-08-17 08:26:30 -04:00
Anders Kaseorg 9187e307c6 mosh-client: Print exceptions after the client is shut down
Otherwise the printed exception may be immediately hidden when the
terminal exits alternate screen mode.

Signed-off-by: Anders Kaseorg <andersk@mit.edu>
2013-08-17 08:26:30 -04:00
Keith Winstein 45bba44c83 mosh-server: Allow startup without PTY 2013-07-15 11:20:07 -04:00
Barosl LEE c6bf3a2025 Implement bracketed paste mode
Allow bracketed paste mode-setting control sequences to be passed to the
outer terminal.

Signed-off-by: Barosl LEE <vcs@barosl.com>

Closes #430
2013-07-01 03:18:16 -04:00
Daniel "Tracerneo" Ziółkowski 06561d3500 Add support for ECMA-48 escape sequence for italic
Closes #443
2013-07-01 03:08:25 -04:00
Andrew Chin d8711618c9 Set MACOSX_DEPLOYMENT_TARGET so that older macs can run the mosh binaries
Closes #424
2013-07-01 02:59:30 -04:00
Keith Winstein c3e31f1d71 Get rid of obsolete DM-Upload-Allowed field 2013-06-05 19:19:05 +02:00
Timo J. Rinne f960a8bcf5 mosh-client: Make terminal escape character configurable
Uses environment variable MOSH_ESCAPE_KEY. Defaults to current Ctrl-^
which is somewhat problematic for many non-US keyboards.

Signed-off-by: Timo J. Rinne <tri@iki.fi>

Closes #425. Closes #215.
2013-05-17 15:05:33 -04:00
Keith Winstein 4792992afa Rename --bind-ip to --bind-server, add =ANY option, add error checking.
Closes #415.
2013-04-28 15:33:36 -04:00
Philipp Haselwarter fc70612de6 mosh perl wrapper: New option --bind-ip={ssh|IP}
Allow overriding the switch passed to mosh-server from -s to -i IP.

Signed-off-by: Philipp Haselwarter <philipp@haselwarter.org>
2013-04-28 15:14:47 -04:00
Jérémie Courrèges-Anglas 9314ea18fa use betoh64 if be64toh not found
Instead of looking for htobe64 which is be available both when
be64toh or betoh64 are, check for the latter functions.  If we
find betoh64 but not be64toh, use compat #defines.  If both
can't be found, search for OSX' OSSwapHostToBigInt64.
Also include sys/types.h in byteorder.h (which is necessary for
byteorder functions on OpenBSD), and incidentally fixes build
of networkfragment.cc.

Fixes build on OpenBSD

Signed-off-by: Jérémie Courrèges-Anglas <jca@wxcvbn.org>
2013-04-16 11:11:45 +02: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
Andrew Chin fbd2d184fb In the OSX build script, link with system libs.
Previously, mosh was linking with macports-provided libs in
/opt/local/lib, which was not portable to users without macports

Closes #411
2013-04-15 14:36:01 -04:00
Anders Kaseorg 8ff636d54e Work around automake bug that dropped portability warnings
There’s a bug in automake ≥ 1.10, < 1.12 where ‘-Wall foreign’
incorrectly turns off warnings about portability issues.  To get
consistent results across automake versions, use ‘foreign -Wall’
instead.

http://debbugs.gnu.org/cgi-bin/bugreport.cgi?bug=7669

Signed-off-by: Anders Kaseorg <andersk@mit.edu>

Closes #413
2013-04-15 13:37:52 -04:00
Anton Lundin fb39fe2c7e Simplify pipe management
We don't need to write perl like C.
2013-04-09 22:31:12 +02:00