summaryrefslogtreecommitdiffstats
path: root/file.c
AgeCommit message (Collapse)Author
2023-04-17Make the check if printing is allowed the same as writing which is lessnicm
confusing.
2023-01-06If a pane is killed, cancel reading from the file. GitHub issue 3422.nicm
2022-08-24Check for NULL returns from bufferevent_new.nicm
2021-08-22Do not double free expanded path in source-file, also remove somenicm
unnecessary assignments.
2021-06-10Fire check callback after cleaning up event so it does not get stuck,nicm
from Jeongho Jang in GitHub issue 2695.
2021-02-12Do not care about the server socket closing if exiting anyway.nicm
2021-02-11Add a couple of helper functions, and flush imsgs on exit.nicm
2021-02-11Move file handling protocol stuff all into file.c so it can be reusednicm
more easily.
2020-05-26Pass the stdout file descriptor from the client as well as stdin and usenicm
them for control clients directly instead of passing everything via the client.
2020-05-08imsg.h needs uio.h, pointed out by deraadtnicm
2019-12-16If /dev/fd/X is a symlink and realpath() expands symlinks, /dev/fd/Xnicm
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.
2019-12-16Need to include message size in the maximum buffer calculation.nicm
2019-12-16Instead of using large buffers in imsgs, add the data or path onto the end.nicm
2019-12-12Do not check if client is dead if it is NULL.nicm
2019-12-12Rewrite the code for reading and writing files. Now, if the client isnicm
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.