Commit graph

79 commits

Author SHA1 Message Date
75a511a749 (main, intr) [!_WIN32]: signal() is a portability headache. Switch to
sigaction().
2005-12-28 16:59:20 +00:00
1ec32d97c4 Fix the previous revision. 2005-12-28 16:38:19 +00:00
87ace6afe4 (handleintr): Move to main.c. Internal linkage. Remove empty
handle.c
(interrupt): Internal linkage.

(interrupt): Use proper type for access from signal handler.
(intr): Don't increment to set, it's unobvious and it could overflow.
2005-12-28 16:16:41 +00:00
3aebb68ee7 Include config.h. 2005-12-27 18:04:19 +00:00
Ron Koenderink
a5952bab1e [_NTSDK]: Remove _NTSDK not needed. 2005-10-22 19:19:16 +00:00
d253e1266f (hostaddr, hostconnect): Leave printing messages to caller.
(main): Clarify messages.

(hostport) [_WIN32]: Remove useless conditional code.

(main): Fall back to compiled-in host only if environment doesn't
supply one, not if it can't be resolved.  Same for port.
2005-09-23 17:55:24 +00:00
744d118768 Document Windows lossage and work-around. 2005-07-01 19:52:43 +00:00
Ron Koenderink
dfe767e7e0 (main) [_WIN32]: Windows putchar() screws up when printing multibyte
strings bytewise unless the stream is buffered.  Switch stdout to
line-buffered mode.
(login): Explicitly flush stdout, because Windows doesn't implement
line-buffering faithfully.
2005-06-30 16:10:42 +00:00
7ef7aa83b8 Client UTF-8 support.
(login): New parameter utf8.  If set, request option utf-8 from
server.
(expect, recvline): Split recvline() out of expect().  Replace or
remove some unhelpful diagnostics.
(eight_bit_clean): New.
(screen): If eight_bit_clean is set, highlighting is switched with
SO/SI.  Else characters with MSB set are highlighted.
(main): New option -u to request UTF-8 and set eight_bit_clean.
2005-05-27 17:00:25 +00:00
345ad3dfe0 Update copyright notice. 2005-03-16 22:03:16 +00:00
750884dbc7 Fix the previous rev. 2005-03-16 06:27:15 +00:00
Marc Olzheim
6a99690e4e Get rid of "s_char", "register" and 0 used instead of NULL in the
client source.  No functional changes.
2005-03-15 21:47:41 +00:00
Ron Koenderink
9faba52ba4 (main, termio): Add the ability to set the username.
Get it from environment variable LOGNAME if set,
else get the user name from the system.

(main) [_DWIN32]: Add stdin redirection ability to the Win32 port.
The client reads until stdin redirection empty and then terminates.
2004-10-19 01:11:31 +00:00
fac342ed49 Update copyright notice. 2004-09-07 15:07:16 +00:00
5233f7029f (main, intr, handleintr, termio): Do the right thing for Windows so ^C
aborts to the current command, as it should.  From Ron Koenderink.
2004-02-22 07:27:08 +00:00
e7811102a3 Declare tags.c variables in tags.h. Declare stuff with external
linkage that is not in any other header in misc.h.  Remove some
redundant declarations elsewhere.
(prompt, doredir, dopipe, doexecute, output, screen, parsedelay):
Static linkage.
2004-02-20 08:22:28 +00:00
d59bc20516 Properly declare functions in headers; remove redundant declarations. 2004-02-19 12:39:17 +00:00
237baffca9 Supply prototypes where possible. This uncovered type errors with
thread entrypoints:
(lwpSelect, shutdown_sequence): Parameters didn't match thread entry
point prototype.
(lwpEntryPoint): Arguments didn't match thread entry point prototype.

Change linkage of functions without prototype declaration to static
where possible.

Remove some superflous declarations, replace others by suitable
includes.
2004-02-17 17:59:30 +00:00
7dbb87b0e0 Windows cleanup: include proper headers, remove unused variables, fix
type of signal handler.  Mostly from Ron Koenderink.
2004-02-16 17:44:38 +00:00
9cfb72ab45 (main, USERNAME): Change Windows user name from win-empcl2.8 to nobody
to get rid of the version number.  Keeping it up-to-date by hand is
too much work, but leaving it at 2.8 would be confusing.
2004-02-12 16:50:48 +00:00
51c3215cf8 Fix previous rev. 2004-02-10 18:11:44 +00:00
ab95ad96d2 [_WIN32] Fix previous rev. 2004-01-20 15:43:44 +00:00
4ce5f988d0 Portability fixes: don't declare library functions, include
appropriate headers.  Also remove some unused declarations.
2004-01-15 13:43:50 +00:00
56dce5a8c4 (main): Portability bug: code passed bit_fdmask to select(). This
breaks the fd_set abstraction, and works only with the traditional
Unix implementation of fd_set.  Use fd_set and its operations instead.
Remove unused source files.
2004-01-15 09:39:51 +00:00
64afd7747b (index, rindex): Obsolete BSDisms; remove. Use standard strchr() and
strrchr() instead.
(setbuffer): Obsolete BSDism, unused; remove.
2004-01-08 18:15:13 +00:00
4ae9c417b3 (bzero, bcopy): Obsolete BSDisms; remove. Remove some calls without
effect.  Replace calls by struct assignment where possible.  Replace
clear buffer, copy string to buffer by strncpy().  Use assignment to
clear when that's clearer.  Replace overlapping copy through bounce
buffer by memmove().  Replace rest by standard memset() and memcpy().
Also use sizeof() instead of literal array sizes for robustness, and
instead of symbolic array sizes for clarity.
2004-01-08 17:54:28 +00:00
3bf2b1b47f errno may not be a variable; users must include errno.h instead of
declaring it like `extern int errno'.
2003-12-17 21:18:12 +00:00
9b7adfbecc Indented with src/scripts/indent-emp. 2003-09-02 20:48:48 +00:00
d8b7fdfae1 Import of Empire 4.2.12 2003-08-23 12:23:04 +00:00