aboutsummaryrefslogtreecommitdiff
path: root/job.c
Commit message (Collapse)AuthorAge
* Mention that if-shell and #() use /bin/sh.nicm2022-02-01
|
* For open/openat, if the flags parameter does not contain O_CREAT, thederaadt2021-10-24
| | | | | | | | | | | | | 3rd (variadic) mode_t parameter is irrelevant. Many developers in the past have passed mode_t (0, 044, 0644, or such), which might lead future people to copy this broken idiom, and perhaps even believe this parameter has some meaning or implication or application. Delete them all. This comes out of a conversation where tb@ noticed that a strange (but intentional) pledge behaviour is to always knock-out high-bits from mode_t on a number of system calls as a safety factor, and his bewilderment that this appeared to be happening against valid modes (at least visually), but no sorry, they are all irrelevant junk. They could all be 0xdeafbeef. ok millert
* Add -e flag to set environment for popup, from Alexis Hildebrandt innicm2021-10-11
| | | | GitHub issue 2924.
* Fill in some other bits on new panes.nicm2021-08-13
|
* Add menu options to convert a popup into a pane.nicm2021-08-13
|
* Drop support for popups where the content is provided directly to tmuxnicm2021-03-02
| | | | | | (which does not have many practical uses) and only support running a program in the popup. display-popup is now simpler and can accept multiple arguments to avoid escaping problems (like the other commands).
* Check return value of chdir() to stop a silly warning with somenicm2021-02-19
| | | | compilers, GitHub issue 2573.
* Add 'e' key in buffer mode to open the buffer in an editor.nicm2020-05-16
|
* Add support for overlay popup boxes to show text or output temporarilynicm2020-03-24
| | | | | above the normal layout. These work similarly to menus and are created with the display-popup command.
* Add a flag to run a background process in a pty as well, not used fornicm2020-03-19
| | | | anything yet.
* When system calls indicate an error they return -1, not some arbitraryderaadt2019-06-28
| | | | | | value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
* evbuffer_new and bufferevent_new can both fail (when malloc fails) andnicm2018-11-19
| | | | return NULL. GitHub issue 1547.
* Do not printf NULL.nicm2018-10-28
|
* Use same working directory rules for jobs as new windows rather thannicm2018-09-27
| | | | always starting in home, GitHub issue 1488.
* all_jobs can be static.nicm2018-08-23
|
* Move job struct into job.c.nicm2018-08-23
|
* Add a missing client-detached hook when the server shuts down, and donicm2018-03-08
| | | | | not exit until jobs started from run-shell/if-shell have finished (add a job flags member and a flag to indicate other jobs). GitHub issue 1245.
* Because ignore SIGCHLD early, letting signal_del restore it doesn't worknicm2017-07-14
| | | | | correctly, so set it explicitly back to default (and the others for good measure).
* Block signals between forking and clearing signal handlers (or callingnicm2017-07-12
| | | | | | event_reinit) - if the child gets a signal and fires the libevent signal handler during this period it could write a signal into the parent's signal pipe. GitHub issue 1001 from Aaron van Geffen.
* Move signal code into proc.c.nicm2017-07-12
|
* Style and spacing nits.nicm2017-05-31
|
* Do not update TERM into config file parsing has finished.nicm2017-04-25
|
* If a #() command doesn't exit, use its most recent line of output (itnicm2017-04-20
| | | | | | | must be a full line). Don't let it redraw the status line more than once a second. Requested by someone about 10 years ago...
* Move server_fill_environ into environ.c and move some other common codenicm2017-03-09
| | | | into it.
* Loads more static, except for cmd-*.c and window-*.c.nicm2016-10-10
|
* I no longer use my SourceForge address so replace it.nicm2016-01-19
|
* Use __unused rather than rolling our own.nicm2015-11-18
|
* Because pledge(2) does not allow us to pass directory file descriptorsnicm2015-10-31
| | | | | | | | | around, we can't use file descriptors for the working directory because we will be unable to pass it to a privileged process to tell it where to read or write files or spawn children. So move tmux back to using strings for the current working directory. We try to check it exists with access() when it is set but ultimately fall back to ~ if it fails at time of use (or / if that fails too).
* Like options, move the environ struct into environ.c.nicm2015-10-28
|
* Use an explicit job state instead of avoid closing our side of thenicm2015-06-17
| | | | | | | socketpair and setting it to -1 to mark when the other side is closed. This avoids closing it while the libevent bufferevent still has it (it could try to add it to the polled set which some mechanisms don't like). Fixes part a problem reported by Bruno Sutic.
* Set working directory for run-shell and if-shell.nicm2015-04-24
|
* Tidy up some includes.nicm2014-10-20
|
* Don't leak socketpair file descriptors if fork fails. Spotted by Balazsnicm2014-04-14
| | | | Kezes.
* Use format_get_command() and some spacing tweaks.nicm2013-10-10
|
* %zu format for size_t.Nicholas Marriott2013-04-17
|
* Set EV_WRITE for jobs or run/if-shell jobs can hang. From Chris Johnsen.Nicholas Marriott2013-04-10
|
* Extend jobs to support writing and use that for copy-pipe instead ofNicholas Marriott2013-03-25
| | | | popen, from Chris Johnsen.
* No more lint means no more ARGSUSED.Nicholas Marriott2013-03-22
|
* xfree is not particularly helpful, remove it. From Thomas Adam.Nicholas Marriott2012-07-10
|
* Call bufferevent_free before closing file descriptor associated with itNicholas Marriott2012-01-29
| | | | | or bugs in $EventMechanism on $OtherOS makes libevent get it's knickers in a twist. From Dylan Alex Simon.
* Simplify the way jobs work and drop the persist type, so all jobs areNicholas Marriott2011-01-26
| | | | | | | | | | | | | | | | | fire-and-forget. Status jobs now managed with two trees of output (new and old), rather than storing the output in the jobs themselves. When the status line is processed any jobs which don't appear in the new tree are started and the output from the old tree displayed. When a job finishes it updates the new tree with its output and that is used for any subsequent redraws. When the status interval expires, the new tree is moved to the old so that all jobs are run again. This fixes the "#(echo %H:%M:%S)" problem which would lead to thousands of identical persistent jobs and high memory use (this can still be achieved by adding "sleep 30" but that is much less likely to happen by accident).
* Use LIST_* not SLIST_*.Nicholas Marriott2011-01-26
|
* Set $TMUX without the session when background jobs are run.Nicholas Marriott2011-01-23
|
* Move all calls to fcntl(...O_NONBLOCK) into a function and clear theNicholas Marriott2011-01-08
| | | | | flag on the stdio file descriptors before closing them (fixes things like "tmux ls && cat").
* Trying to set FD_CLOEXEC on every fd is a lost cause, just useNicholas Marriott2010-10-16
| | | | closefrom() before exec.
* Do not call event_del() for signals after fork(), just use sigaction()Nicholas Marriott2010-08-19
| | | | | directly instead - calling libevent functions after fork() w/o event_reinit() is a bad idea, even if in this case it was harmless.
* Put this back in with the initialisation in the right order.Nicholas Marriott2010-05-04
|
* Revert last change, it appears to be broken somehow.Nicholas Marriott2010-05-04
|
* Make signal handler setup/teardown two common functions instead of six,Nicholas Marriott2010-05-03
| | | | | and reset SIGCHLD after fork to fix problems with some shells. From Romain Francois.
* Run job commands explicitly in the global enviroment (which can beNicholas Marriott2010-04-04
| | | | | modified with setenv -g) rather than with the environment tmux started with.