aboutsummaryrefslogtreecommitdiff
path: root/file.c
Commit message (Collapse)AuthorAge
* Merge branch 'obsd-master'Thomas Adam2020-05-26
|\
| * Pass the stdout file descriptor from the client as well as stdin and usenicm2020-05-26
| | | | | | | | | | them for control clients directly instead of passing everything via the client.
| * imsg.h needs uio.h, pointed out by deraadtnicm2020-05-08
| |
* | Portable does not need sys/queue.h.Nicholas Marriott2020-05-03
| |
* | Remove imsg.h.Nicholas Marriott2019-12-16
|/
* If /dev/fd/X is a symlink and realpath() expands symlinks, /dev/fd/Xnicm2019-12-16
| | | | | | | ends up pointing to the wrong place before it is passed to the client. The path is only used internally so there is no real need for realpath(), remove it and move the get_path function to file.c where all the callers are.
* Need to include message size in the maximum buffer calculation.nicm2019-12-16
|
* Instead of using large buffers in imsgs, add the data or path onto the end.nicm2019-12-16
|
* Do not check if client is dead if it is NULL.nicm2019-12-12
|
* Rewrite the code for reading and writing files. Now, if the client isnicm2019-12-12
not attached, the server process asks it to open the file, similar to how works for stdin, stdout, stderr. This makes special files like /dev/fd/X work (used by some shells). stdin, stdout and stderr and control mode are now just special cases of the same mechanism. This will also make it easier to use for other commands that read files such as source-file.