aboutsummaryrefslogtreecommitdiff
path: root/include/error.h
diff options
context:
space:
mode:
authorCharles Cabergs <me@cacharle.xyz>2020-08-27 19:13:28 +0200
committerCharles Cabergs <me@cacharle.xyz>2020-08-27 21:13:39 +0200
commit95a16d2d88c8628ab0ae76f3ae04dfebee566950 (patch)
treefb8ca171c2ce4fa91a294526764f579f1a7343f3 /include/error.h
parenta680cf09a3fa4b7c6adc38e4297ee5535172826b (diff)
downloadminishell-95a16d2d88c8628ab0ae76f3ae04dfebee566950.tar.gz
minishell-95a16d2d88c8628ab0ae76f3ae04dfebee566950.tar.bz2
minishell-95a16d2d88c8628ab0ae76f3ae04dfebee566950.zip
Fising tok_lst_new uninitialized next, Added tok_lst_debug, Fixing parse_cmd
Diffstat (limited to 'include/error.h')
-rw-r--r--include/error.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/include/error.h b/include/error.h
new file mode 100644
index 0000000..941f1b2
--- /dev/null
+++ b/include/error.h
@@ -0,0 +1,36 @@
+/* ************************************************************************** */
+/* */
+/* ::: :::::::: */
+/* error.h :+: :+: :+: */
+/* +:+ +:+ +:+ */
+/* By: charles <me@cacharle.xyz> +#+ +:+ +#+ */
+/* +#+#+#+#+#+ +#+ */
+/* Created: 2020/08/27 20:34:25 by charles #+# #+# */
+/* Updated: 2020/08/27 20:38:52 by charles ### ########.fr */
+/* */
+/* ************************************************************************** */
+
+#ifndef ERROR_H
+# define ERROR_H
+
+# include <stdarg.h>
+# include "libft_io.h"
+
+/*
+** error.c
+*/
+
+typedef enum
+{
+ ERR_FATAL = -1,
+ ERR_NONE = 0,
+ ERR_AMBIGUOUS_REDIR = 1,
+ ERR_OPEN = 1,
+ ERR_CMD_NOT_FOUND = 127,
+ ERR_SYNTAX = 2,
+} t_err;
+
+void errorf(const char *format, ...);
+void verrorf(const char *format, va_list ap);
+
+#endif