summaryrefslogtreecommitdiff
path: root/src/os_unix.c
Commit message (Collapse)AuthorAgeFilesLines
* patch 8.0.1820: terminal window redirecting stdout does not show stderrv8.0.1820Bram Moolenaar2018-05-121-1/+6
| | | | | | | Problem: Terminal window redirecting stdout does not show stderr. (Matéo Zanibelli) Solution: When stdout is not connected to pty_master_fd then use it for stderr. (closes #2903)
* patch 8.0.1795: lose contact with jobs when :gui forksv8.0.1795Bram Moolenaar2018-05-051-5/+13
| | | | | | | Problem: Lose contact with jobs when :gui forks. Solution: Don't fork when there is a running job. Make log message for a died job clearer. Also close the terminal when stderr and stdout are the same FD.
* patch 8.0.1761: job in terminal window with no output channel is killedv8.0.1761Bram Moolenaar2018-04-241-7/+8
| | | | | | Problem: Job in terminal window with no output channel is killed. Solution: Keep the job running when the input is a tty. (Ozaki Kiichi, closes #2734)
* patch 8.0.1753: various warnings from a static analyserv8.0.1753Bram Moolenaar2018-04-241-1/+1
| | | | | | Problem: Various warnings from a static analyser Solution: Add type casts, remove unneeded conditions. (Christian Brabandt, closes #2770)
* patch 8.0.1745: build failure on MS-Windowsv8.0.1745Bram Moolenaar2018-04-211-85/+0
| | | | | Problem: Build failure on MS-Windows. Solution: Build job arguments for MS-Windows. Fix allocating job twice.
* patch 8.0.1665: when running a terminal from the GUI 'term' is not usefulv8.0.1665Bram Moolenaar2018-04-051-2/+14
| | | | | Problem: When running a terminal from the GUI 'term' is not useful. Solution: Use $TERM in the GUI if it starts with "xterm". (closes #2776)
* patch 8.0.1629: Mac: getpagesize() is deprecatedv8.0.1629Bram Moolenaar2018-03-221-1/+1
| | | | | Problem: Mac: getpagesize() is deprecated. Solution: Use sysconf() instead. (Ozaki Kiichi, closes #2741)
* patch 8.0.1613: warning for unused variable in tiny buildv8.0.1613Bram Moolenaar2018-03-171-1/+1
| | | | | Problem: Warning for unused variable in tiny build. (Tony Mechelynck) Solution: Move declaration to inner block.
* patch 8.0.1609: shell commands in the GUI use a dumb terminalv8.0.1609Bram Moolenaar2018-03-161-45/+153
| | | | | | Problem: Shell commands in the GUI use a dumb terminal. Solution: Add the "!" flag to 'guioptions' to execute system commands in a special terminal window. Only for Unix now.
* patch 8.0.1572: Mac: getting memory size doesn't work everywherev8.0.1572Bram Moolenaar2018-03-051-2/+2
| | | | | Problem: Mac: getting memory size doesn't work everywhere. Solution: Use MACOS_X instead of MACOS_X_DARWIN. (Kazunobu Kuriyama)
* patch 8.0.1568: can't build on older Mac, header file is missingv8.0.1568Bram Moolenaar2018-03-051-1/+0
| | | | | Problem: Can't build on older Mac, header file is missing. Solution: Remove the header file. (Ozaki Kiichi, closes #2691)
* patch 8.0.1564: too many #ifdefsv8.0.1564Bram Moolenaar2018-03-041-4/+1
| | | | | | Problem: Too many #ifdefs. Solution: Graduate the +autocmd feature. Takes away 450 #ifdefs and increases code size of tiny Vim by only 40 Kbyte.
* patch 8.0.1552: may leak file descriptors when executing jobv8.0.1552Bram Moolenaar2018-02-271-3/+15
| | | | | Problem: May leak file descriptors when executing job. Solution: Close more file descriptors. (Ozaki Kiichi, closes #2531)
* patch 8.0.1551: on Mac 'maxmemtot' is set to a weird valuev8.0.1551Bram Moolenaar2018-02-271-8/+67
| | | | | | | Problem: On Mac 'maxmemtot' is set to a weird value. Solution: For Mac use total memory and subtract system memory. For other systems accept both a 32 bit and 64 bit result. (Ozaki Kiichi, closes #2646)
* patch 8.0.1496: clearing a pointer takes two linesv8.0.1496Bram Moolenaar2018-02-101-7/+4
| | | | | | Problem: Clearing a pointer takes two lines. Solution: Add VIM_CLEAR() and replace vim_clear(). (Hirohito Higashi, closes #2629)
* patch 8.0.1405: duplicated code for getting a typed characterv8.0.1405Bram Moolenaar2017-12-181-30/+2
| | | | | | | Problem: Duplicated code for getting a typed character. CursorHold is called too often in the GUI. (lilydjwg) Solution: Refactor code to move code up from mch_inchar(). Don't fire CursorHold if feedkeys() was used. (closes #2451)
* patch 8.0.1312: balloon_show() only works in terminal when compiled with GUIv8.0.1312Bram Moolenaar2017-11-181-6/+6
| | | | | | Problem: balloon_show() only works in terminal when compiled with the GUI. Solution: Add FEAT_BEVAL_GUI and refactor to move common code out of the GUI specific file.
* patch 8.0.1309: cannot use 'balloonexpr' in a terminalv8.0.1309Bram Moolenaar2017-11-181-14/+51
| | | | | | Problem: Cannot use 'balloonexpr' in a terminal. Solution: Add 'balloonevalterm' and add code to handle mouse movements in a terminal. Initial implementation for Unix with GUI.
* patch 8.0.1300: file permissions may end up wrong when writingv8.0.1300Bram Moolenaar2017-11-161-3/+14
| | | | | | Problem: File permissions may end up wrong when writing. Solution: Use fchmod() instead of chmod() when possible. Don't truncate until we know we can change the file.
* patch 8.0.1236: Mac features are confusingv8.0.1236Bram Moolenaar2017-10-281-11/+0
| | | | | | Problem: Mac features are confusing. Solution: Make feature names more consistent, add "osxdarwin". Rename feature flags, cleanup Mac code. (Kazunobu Kuriyama, closes #2178)
* patch 8.0.1176: job_start() does not handle quote and backslash correctlyv8.0.1176Bram Moolenaar2017-10-061-9/+17
| | | | | Problem: Job_start() does not handle quote and backslash correctly. Solution: Remove quotes, recognize and remove backslashes.
* patch 8.0.1170: using termdebug results in 100% CPU timev8.0.1170Bram Moolenaar2017-10-011-4/+12
| | | | | Problem: Using termdebug results in 100% CPU time. (tomleb) Solution: Use polling instead of select().
* patch 8.0.1074: ":term NONE" does not work on MS-Windowsv8.0.1074Bram Moolenaar2017-09-081-2/+8
| | | | | | Problem: ":term NONE" does not work on MS-Windows. Solution: Make it work. Split "pty" into "pty_in" and "pty_out". (Yasuhiro Matsumoto, closes #2058, closes #2045)
* patch 8.0.1064: Coverity warns for leaking resourcev8.0.1064Bram Moolenaar2017-09-051-0/+3
| | | | | Problem: Coverity warns for leaking resource. Solution: Free pty_master_fd on failure.
* patch 8.0.1051: cannot run terminal with spaces in argumentv8.0.1051Bram Moolenaar2017-09-031-1/+10
| | | | | | Problem: Cannot run terminal with spaces in argument. Solution: Accept backslash to escape space and other characters. (closes #1999)
* patch 8.0.1033: detecting background color does not work in screenv8.0.1033Bram Moolenaar2017-09-011-0/+1
| | | | | | | | Problem: Detecting background color does not work in screen, even when it is working like an xterm. Solution: Make "screen.xterm" use termcap entries like an xterm. (Lubomir Rintel, closes #2048) When termresponse version is huge also recognize as not being an xterm.
* patch 8.0.1000: cannot open a terminal without running a job in itv8.0.1000Bram Moolenaar2017-08-261-1/+24
| | | | | Problem: Cannot open a terminal without running a job in it. Solution: Make ":terminal NONE" open a terminal with a pty.
* patch 8.0.0980: Coverity warning for failing to open /dev/nullv8.0.0980Bram Moolenaar2017-08-211-0/+8
| | | | | Problem: Coverity warning for failing to open /dev/null. Solution: When /dev/null can't be opened exit the child.
* patch 8.0.0976: cannot send lines to a terminal jobv8.0.0976Bram Moolenaar2017-08-201-3/+11
| | | | | | Problem: Cannot send lines to a terminal job. Solution: Make [range]terminal send selected lines to the job. Use ++rows and ++cols for the terminal size.
* patch 8.0.0932: terminal may not use right characters for BS and Enterv8.0.0932Bram Moolenaar2017-08-131-30/+54
| | | | | Problem: Terminal may not use right characters for BS and Enter. Solution: Get the characters from the tty.
* patch 8.0.0902: cannot specify directory or environment for a jobv8.0.0902Bram Moolenaar2017-08-111-0/+19
| | | | | | Problem: Cannot specify directory or environment for a job. Solution: Add the "cwd" and "env" arguments to job options. (Yasuhiro Matsumoto, closes #1160)
* patch 8.0.0899: function name mch_stop_job() is confusingv8.0.0899Bram Moolenaar2017-08-111-1/+1
| | | | | Problem: Function name mch_stop_job() is confusing. Solution: Rename to mch_signal_job().
* patch 8.0.0854: no redraw after terminal was closedv8.0.0854Bram Moolenaar2017-08-031-12/+26
| | | | | | | Problem: No redraw after terminal was closed. Solution: Set typebuf_was_filled. (Yasuhiro Matsumoto, closes #1925, closes #1924) Add function to check for messages even when input is available.
* patch 8.0.0846: cannot get the name of the pty of a jobv8.0.0846Bram Moolenaar2017-08-031-12/+8
| | | | | | Problem: Cannot get the name of the pty of a job. Solution: Add the "tty" entry to the job info. (Ozaki Kiichi, closes #1920) Add the term_gettty() function.
* patch 8.0.0842: using slave pty after closing itv8.0.0842Bram Moolenaar2017-08-021-13/+13
| | | | | Problem: Using slave pty after closing it. Solution: Do the ioctl() before dup'ing it.
* patch 8.0.0839: cannot kill a job in a terminal with CTRL-Cv8.0.0839Bram Moolenaar2017-08-011-15/+35
| | | | | Problem: Cannot kill a job in a terminal with CTRL-C. Solution: Set the controlling tty and send SIGINT. (closes #1910)
* patch 8.0.0834: can't build without the client-server featurev8.0.0834Bram Moolenaar2017-08-011-0/+6
| | | | | Problem: Can't build without the client-server feature. Solution: Add #ifdef.
* patch 8.0.0829: job running in terminal can't communicate with Vimv8.0.0829Bram Moolenaar2017-08-011-1/+9
| | | | | | Problem: A job running in a terminal window cannot easily communicate with the Vim it is running in. Solution: Pass v:servername in an environment variable. (closes #1908)
* patch 8.0.0827: Coverity: could leak pty file descriptorv8.0.0827Bram Moolenaar2017-08-011-0/+16
| | | | | Problem: Coverity: could leak pty file descriptor, theoretically. Solution: If channel is NULL, free the file descriptors.
* patch 8.0.0797: finished job in terminal window is not handledv8.0.0797Bram Moolenaar2017-07-281-0/+3
| | | | | | Problem: Finished job in terminal window is not handled. Solution: Add the scrollback buffer. Use it to fill the buffer when the job has ended.
* patch 8.0.0793: using wrong terminal name for terminal windowv8.0.0793Bram Moolenaar2017-07-281-1/+2
| | | | | | Problem: Using wrong terminal name for terminal window. Solution: When 'term' starts with "xterm" use it for $TERM in a terminal window.
* patch 8.0.0753: no size reports to a job running in a terminalv8.0.0753Bram Moolenaar2017-07-221-0/+42
| | | | | | Problem: A job running in a terminal does not get notified of changes in the terminal size. Solution: Use ioctl() and SIGWINCH to report the terminal size.
* patch 8.0.0748: running Vim in terminal window doesn't use the right colorsv8.0.0748Bram Moolenaar2017-07-221-0/+10
| | | | | | | Problem: When running Vim in a terminal window it does not detect the right number of colors available. Solution: Detect the version string that libvterm returns. Pass the number of colors in $COLORS.
* patch 8.0.0746: when :term fails the job is not properly cleaned upv8.0.0746Bram Moolenaar2017-07-221-1/+3
| | | | | | Problem: When :term fails the job is not properly cleaned up. Solution: Free the terminal. Handle a job that failed to start. (closes #1858)
* patch 8.0.0744: terminal window does not use a ptyv8.0.0744Bram Moolenaar2017-07-221-57/+75
| | | | | Problem: A terminal window uses pipes instead of a pty. Solution: Add pty support.
* patch 8.0.0741: cannot build with HPUXv8.0.0741Bram Moolenaar2017-07-221-1/+1
| | | | | Problem: Cannot build with HPUX. Solution: Rename envbuf_TERM to envbuf_Term. (John Marriott)
* patch 8.0.0739: terminal resizing doesn't work well.v8.0.0739Bram Moolenaar2017-07-201-13/+31
| | | | | | Problem: Terminal resizing doesn't work well. Solution: Resize the terminal to the Vim window and the other way around. Avoid mapping typed keys. Set the environment properly.
* patch 8.0.0661: recognizing urxvt mouse codes does not work wellv8.0.0661Bram Moolenaar2017-06-221-6/+11
| | | | | Problem: Recognizing urxvt mouse codes does not work well. Solution: Recognize "Esc[*M" and "Esc[*m". (Maurice Bos, closes #1486)
* patch 8.0.0526: Coverity complains about possible negative valuev8.0.0526Bram Moolenaar2017-03-301-2/+8
| | | | | Problem: Coverity complains about possible negative value. Solution: Check return value of ftell() not to be negative.
* patch 8.0.0512: check for available characters takes too longv8.0.0512Bram Moolenaar2017-03-251-1/+1
| | | | | | Problem: Check for available characters takes too long. Solution: Only check did_start_blocking if wtime is negative. (Daisuke Suzuki, closes #1591)