minishell/src/ft_errno.h
Jérôme Guélen bed41f4a6f
Expansion: A fix attempt
No time left to check before going home
2025-03-21 10:14:34 +01:00

36 lines
1.3 KiB
C

/* ************************************************************************** */
/* */
/* ::: :::::::: */
/* ft_errno.h :+: :+: :+: */
/* +:+ +:+ +:+ */
/* By: jguelen <jguelen@student.42.fr> +#+ +:+ +#+ */
/* +#+#+#+#+#+ +#+ */
/* Created: 2025/02/21 12:40:58 by khais #+# #+# */
/* Updated: 2025/03/21 10:14:26 by jguelen ### ########.fr */
/* */
/* ************************************************************************** */
#ifndef FT_ERRNO_H
# define FT_ERRNO_H
typedef enum e_errno
{
FT_EERRNO = -2,
FT_EGET = -1,
FT_ESUCCESS = 0,
FT_ENOMEM,
FT_EINVAL,
FT_EBADID,
FT_EUNEXPECTED_PIPE,
FT_EMALFORMED_REDIRECTION,
FT_STATFAIL,
FT_ISDIR,
FT_EMAXERRNO,
} t_errno;
t_errno ft_errno(t_errno errno);
t_errno ft_errno_get(void);
char *ft_strerror(t_errno errno);
t_errno ft_perror(char *desc);
#endif