nghttp2_int.h 1.0 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. /*
  2. * Copyright (C) 2015-2018 Alibaba Group Holding Limited
  3. */
  4. #ifndef NGHTTP2_INT_H
  5. #define NGHTTP2_INT_H
  6. #ifdef HAVE_CONFIG_H
  7. #include <config.h>
  8. #endif /* HAVE_CONFIG_H */
  9. #include "nghttp2.h"
  10. /* Macros, types and constants for internal use */
  11. /* "less" function, return nonzero if |lhs| is less than |rhs|. */
  12. typedef int (*nghttp2_less)(const void *lhs, const void *rhs);
  13. /* Internal error code. They must be in the range [-499, -100],
  14. inclusive. */
  15. typedef enum {
  16. NGHTTP2_ERR_CREDENTIAL_PENDING = -101,
  17. NGHTTP2_ERR_IGN_HEADER_BLOCK = -103,
  18. NGHTTP2_ERR_IGN_PAYLOAD = -104,
  19. /*
  20. * Invalid HTTP header field was received but it can be treated as
  21. * if it was not received because of compatibility reasons.
  22. */
  23. NGHTTP2_ERR_IGN_HTTP_HEADER = -105,
  24. /*
  25. * Invalid HTTP header field was received, and it is ignored.
  26. * Unlike NGHTTP2_ERR_IGN_HTTP_HEADER, this does not invoke
  27. * nghttp2_on_invalid_header_callback.
  28. */
  29. NGHTTP2_ERR_REMOVE_HTTP_HEADER = -106
  30. } nghttp2_internal_error;
  31. #endif /* NGHTTP2_INT_H */