comp_err.c 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /*
  2. * Generated by util/mkerr.pl DO NOT EDIT
  3. * Copyright 1995-2021 The OpenSSL Project Authors. All Rights Reserved.
  4. *
  5. * Licensed under the Apache License 2.0 (the "License"). You may not use
  6. * this file except in compliance with the License. You can obtain a copy
  7. * in the file LICENSE in the source distribution or at
  8. * https://www.openssl.org/source/license.html
  9. */
  10. #include <openssl/err.h>
  11. #include <openssl/comperr.h>
  12. #include "crypto/comperr.h"
  13. #ifndef OPENSSL_NO_COMP
  14. # ifndef OPENSSL_NO_ERR
  15. static const ERR_STRING_DATA COMP_str_reasons[] = {
  16. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_BROTLI_DECODE_ERROR),
  17. "brotli decode error"},
  18. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_BROTLI_ENCODE_ERROR),
  19. "brotli encode error"},
  20. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_BROTLI_NOT_SUPPORTED),
  21. "brotli not supported"},
  22. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_ZLIB_DEFLATE_ERROR),
  23. "zlib deflate error"},
  24. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_ZLIB_INFLATE_ERROR),
  25. "zlib inflate error"},
  26. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_ZLIB_NOT_SUPPORTED),
  27. "zlib not supported"},
  28. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_ZSTD_COMPRESS_ERROR),
  29. "zstd compress error"},
  30. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_ZSTD_DECODE_ERROR), "zstd decode error"},
  31. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_ZSTD_DECOMPRESS_ERROR),
  32. "zstd decompress error"},
  33. {ERR_PACK(ERR_LIB_COMP, 0, COMP_R_ZSTD_NOT_SUPPORTED),
  34. "zstd not supported"},
  35. {0, NULL}
  36. };
  37. # endif
  38. int ossl_err_load_COMP_strings(void)
  39. {
  40. # ifndef OPENSSL_NO_ERR
  41. if (ERR_reason_error_string(COMP_str_reasons[0].error) == NULL)
  42. ERR_load_strings_const(COMP_str_reasons);
  43. # endif
  44. return 1;
  45. }
  46. #else
  47. NON_EMPTY_TRANSLATION_UNIT
  48. #endif