summaryrefslogtreecommitdiff
path: root/src/file.hh
diff options
context:
space:
mode:
authorMaxime Coste <frrrwww@gmail.com>2016-08-30 22:56:47 +0100
committerMaxime Coste <frrrwww@gmail.com>2016-08-30 22:56:47 +0100
commit8b02bb749dece7690f4919372d19cd40907b91b1 (patch)
tree98e636beca5e83f909d3872586f383e95095851b /src/file.hh
parentd0a29511d28f1481622ac9bb3a6ebfa9f8988c2b (diff)
Add a fd_readable(int fd) helper function
Use it instead of direct calls to select scatered around the code base.
Diffstat (limited to 'src/file.hh')
-rw-r--r--src/file.hh1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/file.hh b/src/file.hh
index 29d979e3..2dde1abb 100644
--- a/src/file.hh
+++ b/src/file.hh
@@ -40,6 +40,7 @@ std::pair<StringView, StringView> split_path(StringView path);
String get_kak_binary_path();
+bool fd_readable(int fd);
String read_fd(int fd, bool text = false);
String read_file(StringView filename, bool text = false);
void write(int fd, StringView data);