diff options
Diffstat (limited to 'thirdparty/libwebp/src/utils/huffman_utils.h')
-rw-r--r-- | thirdparty/libwebp/src/utils/huffman_utils.h | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/thirdparty/libwebp/src/utils/huffman_utils.h b/thirdparty/libwebp/src/utils/huffman_utils.h index 98415c5328..d511dc052c 100644 --- a/thirdparty/libwebp/src/utils/huffman_utils.h +++ b/thirdparty/libwebp/src/utils/huffman_utils.h @@ -63,7 +63,8 @@ typedef struct HuffmanTables { // Allocates a HuffmanTables with 'size' contiguous HuffmanCodes. Returns 0 on // memory allocation error, 1 otherwise. -int VP8LHuffmanTablesAllocate(int size, HuffmanTables* huffman_tables); +WEBP_NODISCARD int VP8LHuffmanTablesAllocate(int size, + HuffmanTables* huffman_tables); void VP8LHuffmanTablesDeallocate(HuffmanTables* const huffman_tables); #define HUFFMAN_PACKED_BITS 6 @@ -91,7 +92,7 @@ struct HTreeGroup { }; // Creates the instance of HTreeGroup with specified number of tree-groups. -HTreeGroup* VP8LHtreeGroupsNew(int num_htree_groups); +WEBP_NODISCARD HTreeGroup* VP8LHtreeGroupsNew(int num_htree_groups); // Releases the memory allocated for HTreeGroup. void VP8LHtreeGroupsFree(HTreeGroup* const htree_groups); @@ -101,8 +102,10 @@ void VP8LHtreeGroupsFree(HTreeGroup* const htree_groups); // the huffman table. // Returns built table size or 0 in case of error (invalid tree or // memory error). -int VP8LBuildHuffmanTable(HuffmanTables* const root_table, int root_bits, - const int code_lengths[], int code_lengths_size); +WEBP_NODISCARD int VP8LBuildHuffmanTable(HuffmanTables* const root_table, + int root_bits, + const int code_lengths[], + int code_lengths_size); #ifdef __cplusplus } // extern "C" |