aboutsummaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
Diffstat (limited to 'include')
-rw-r--r--include/error.h3
-rw-r--r--include/pipe.h9
-rw-r--r--include/util/non_block_input.h8
3 files changed, 20 insertions, 0 deletions
diff --git a/include/error.h b/include/error.h
index 50ca23e..ec0bffe 100644
--- a/include/error.h
+++ b/include/error.h
@@ -26,6 +26,9 @@ enum class error_code
FILE_OFLAG_ERROR,
FILE_POINTER_FAIL_TO_OPEN,
+ // pipe
+ FAIL_TO_OPEN_PIPE,
+
};
class T_error : public std::runtime_error {
diff --git a/include/pipe.h b/include/pipe.h
new file mode 100644
index 0000000..e7d7b67
--- /dev/null
+++ b/include/pipe.h
@@ -0,0 +1,9 @@
+#pragma once
+
+
+namespace ov4
+{
+
+inline int self_pipe_fd[2] = {-1, -1};
+
+} \ No newline at end of file
diff --git a/include/util/non_block_input.h b/include/util/non_block_input.h
new file mode 100644
index 0000000..f5937a7
--- /dev/null
+++ b/include/util/non_block_input.h
@@ -0,0 +1,8 @@
+#pragma once
+
+namespace pv4
+{
+
+int non_block_read_char(char *c, int *src = nullptr);
+
+} \ No newline at end of file