error.h 538 B

1234567891011121314151617181920212223242526272829303132
  1. /*
  2. * File: error.h
  3. * Author: Arthur Brandao
  4. *
  5. * Created on 8 novembre 2018
  6. */
  7. #ifndef ERROR_H
  8. #define ERROR_H
  9. /* --- Macro --- */
  10. #define serror(str) fprintf(stderr, str" : %s\n", serrorlib[serrorno])
  11. /* --- Constantes Generales --- */
  12. #define ERR -1
  13. /* --- Constantes Erreurs --- */
  14. #define SEBADEND 1
  15. #define SEBADET 2
  16. #define SEOPENF 3
  17. #define SEREDIRTYPE 4
  18. #define SEBADREDIR 5
  19. #define SEBADCMD 6
  20. #define SEWC 7
  21. #define SEADDWC 8
  22. /* --- Extern --- */
  23. extern int serrorno;
  24. extern char* serrorlib[];
  25. #endif /* ERROR_H */