aboutsummaryrefslogtreecommitdiff
path: root/server-msg.c
Commit message (Collapse)AuthorAge
* Support for individual session idle time locking. May be enabled by turning offNicholas Marriott2009-10-10
| | | | | | | | | | | | | the lock-server option (it is on by default). When this is off, each session locks when it has been idle for the lock-after-time setting. When on, the entire server locks when ALL sessions have been idle for their individual lock-after-time settings. This replaces one global-only option (lock-after-time) with another (lock-server), but the default behaviour is usually preferable so there don't seem to be many alternatives. Diff/idea largely from Thomas Adam, tweaked by me.
* Don't allow locked or suspended clients to limit the size of active clients.Nicholas Marriott2009-09-24
|
* Support -c like sh(1) to execute a command, useful when tmux is a loginNicholas Marriott2009-09-23
| | | | | | | shell. Suggested by halex@. This includes another protocol version increase (the last for now) so again restart the tmux server before upgrading.
* Remove the internal tmux locking and instead detach each client and run theNicholas Marriott2009-09-23
| | | | | | | | | | | | | | command specified by a new option "lock-command" (by default "lock -np") in each client. This means each terminal has to be unlocked individually but simplifies the code and allows the system password to be used to unlock. Note that the set-password command is gone, so it will need to be removed from configuration files, and the -U command line flag has been removed. This is the third protocol version change so again it is best to stop the tmux server before upgrading.
* Trim some code by moving the ioctl(TIOCGWINSZ) after SIGWINCH from the clientNicholas Marriott2009-09-23
| | | | | | | into the server. This is another (the second of four) protocol version changes coming this morning, so again the server should be killed before upgrading.
* Don't attempt to open() the tty path, rely on the client sending its stdin fdNicholas Marriott2009-09-23
| | | | | | | | | with imsg and fatal if it doesn't, then set the FD_CLOEXEC flag in tty_init instead of tty_open to prevent them leaking into child processes if any are created between the two calls. This bumps the protocol version, so the tmux server should be killed before upgrading.
* The default terminal size should be 80x24, not 80x25.Nicholas Marriott2009-09-15
|
* When incorrect passwords are entered, behave similarly to login(1) and backoffNicholas Marriott2009-09-02
| | | | for a bit. Based on a diff from martynas@.
* The cursession member in struct cmd_ctx is always either curclient->session orNicholas Marriott2009-08-23
| | | | NULL when curclient is also NULL, so just eliminate it.
* If the client passes zero for the window size in the identify message (which itNicholas Marriott2009-08-13
| | | | | can, for example on serial terminals), reset it to 80x25, same as for resize messages. Problem reported by kettenis@.
* Have the client pass its stdin fd to the server when identifying itself andNicholas Marriott2009-08-11
| | | | | | | | | have the server use that rather than reopening the tty. If the fd isn't given, use the old behaviour (so no need for a version change). This allows tmux to be used as the shell, so also change so that when working out the command to execute if default-command is empty (the default), tmux will try not execute itself.
* Drop the no_stop argument to tty_close and tty_free in favour of a flag in theNicholas Marriott2009-08-11
| | | | tty struct.
* Switch tmux to use imsg. This is the last major change to make theNicholas Marriott2009-08-11
| | | | | | | | | | | | | | | | | client-server protocol more resilient and make the protocol versioning work properly. In future, the only things requiring a protocol version bump will be changes in the message structs, and (when both client and server have this change) mixing different versions should nicely report an error message. As a side effect this also makes the code tidier, fixes a problem with the way errors reported during server startup were handled, and supports fd passing (which will be used in future). Looked over by eric@, thanks. Please note that mixing a client with this change with an older server or vice versa may cause tmux to crash or hang - tmux should be completely exited before upgrading.
* Infrastructure and commands to manage the environment for processes startedNicholas Marriott2009-08-08
| | | | | | | | | | | | | | | within tmux. There is a global environment, copied from the external environment when the server is started and each sesssion has an (initially empty) session environment which overrides it. New commands set-environment and show-environment manipulate or display the environments. A new session option, update-environment, is a space-separated list of variables which are updated from the external environment into the session environment every time a new session is created - the default is DISPLAY.
* Similar changes for server_msg_dispatch: use a switch instead of a lookup tableNicholas Marriott2009-07-30
| | | | and merge smaller functions inline.
* Rename struct hdrtype to msgtype which is a better name and can be used evenNicholas Marriott2009-07-29
| | | | when struct hdr disappears.
* Make all messages sent between the client and server fixed size.Nicholas Marriott2009-07-26
| | | | | | | | | | | | | | This is the first of two changes to make the protocol more resilient and less sensitive to other changes in the code, particularly with commands. The client now packs argv into a buffer and sends it to the server for parsing, rather than doing it itself and sending the parsed command data. As a side-effect this also removes a lot of now-unused command marshalling code. Mixing a server without this change and a client with or vice versa will cause tmux to hang or crash, please ensure that tmux is entirely killed before upgrading.
* None of the server message functions return anything but 0, so make them allNicholas Marriott2009-07-23
| | | | | | void. Also remove a leftover variable in client.c.
* Handle empty or unset TERM correctly; also fix a fatal() message while here.Nicholas Marriott2009-07-07
|
* When sending a "protocol mismatch" error message, tell the client to exitNicholas Marriott2009-07-07
| | | | afterwards, otherwise it hangs.
* Terminate cwd buffer before running xstrdup on it.Nicholas Marriott2009-06-05
|
* If the prompt is hidden or a password is sent with -U, zero it before freeingNicholas Marriott2009-06-04
| | | | it.
* Import tmux, a terminal multiplexor allowing (among other things) a singleNicholas Marriott2009-06-01
terminal to be switched between several different windows and programs displayed on one terminal be detached from one terminal and moved to another. ok deraadt pirofti