summaryrefslogtreecommitdiff
path: root/main.c
AgeCommit message (Collapse)Author
2025-06-20Clean up whitespace, mixed spaces/tabs, and brace styleHEADmasterNed T. Crigler
2025-06-19Always check the return value of the write() system callNed T. Crigler
dtach was assuming that writes with a small byte count could never fail, and was not handling partial writes for larger byte counts in a few places. This should also suppress unused result warnings from gcc on systems that define _FORTIFY_SOURCE by default.
2025-06-17Add support for -- argument termination markerCiprian Dorin Craciun
This allows one to have executables starting with -; another side-effect of this patch is that in case dtach is used in a script where we can't trust the user input, now the user is not able to inject new options that are interpreted by dtach; (for example it is used like dtach -c socket -- ${@} (cherry picked from commit ff35a7e791225f8d28a27033658070bbb4caa5ff)
2017-03-05Update license header in source files.Ned T. Crigler
Use http://www.gnu.org/licenses/ instead of a postal address as suggested in PR #7.
2016-05-08Update copyrights for 2016.Ned T. Crigler
2015-07-18Update copyrights for 2015.Ned T. Crigler
2015-07-18Add dtach -p.Ned T. Crigler
dtach -p copies the contents of standard input to a session. Based on an initial patch by @johnlane.
2014-08-04Add dtach -N.Ned T. Crigler
dtach -N is similar to dtach -n, except dtach will not daemonize. Based on patches by Ciprian Dorin Craciun and Frank Hunleth.
2008-01-31Fix -e ^<char> to work with lowercase characters.Ned T. Crigler
2008-01-29Update copyrights for 2008.Ned T. Crigler
2007-04-23Always assume that stdin is not a terminal when tcgetattr fails, instead ofNed T. Crigler
printing an error message.
2006-09-27Try to detect and remove stale sockets when dtach -A is used. BeNed T. Crigler
paranoid about this, and only remove the specified file if connect says the connection was refused and stat says the file is a socket. Also dtach -A now only tries to create the socket if the connection was refused or the socket did not exist, instead of on any random error as before.
2006-06-03Print an error message if we could not execute the desired command, instead ofNed T. Crigler
exiting silently. Also make sure the master process waits until the client attaches when using the -A and -c modes, so that the error message has a chance of being seen.
2005-04-10Allow the dtach -n mode to be used without a terminal. If a terminal is notNed T. Crigler
present when dtach is started, we now rely on whatever default terminal settings the kernel uses.
2004-07-01Add documentation for the new redraw option.Ned T. Crigler
2004-06-24Allow the redraw method to be chosen by the user, and include the old Ctrl LNed T. Crigler
character method again.
2004-05-26dtach 0.6Ned T. Crigler
2001-11-30Bump version.Ned T. Crigler
2001-11-05Portability updates thanks to sourceforge's compile farm. dtach should nowNed T. Crigler
work on: FreeBSD, Debian/alpha, Debian/sparc, Debian/PPC, and Solaris. Bump version.
2001-09-28initial import to sourceforgeNed T. Crigler