summaryrefslogtreecommitdiffstatshomepage
path: root/src/lib/util/huffman.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/util/huffman.cpp')
-rw-r--r--src/lib/util/huffman.cpp22
1 files changed, 3 insertions, 19 deletions
diff --git a/src/lib/util/huffman.cpp b/src/lib/util/huffman.cpp
index d3a73315ea9..d8900b45e17 100644
--- a/src/lib/util/huffman.cpp
+++ b/src/lib/util/huffman.cpp
@@ -96,8 +96,8 @@
***************************************************************************/
-#include <stdlib.h>
-#include <assert.h>
+#include <cstdlib>
+#include <cassert>
#include "coretmpl.h"
#include "huffman.h"
@@ -431,7 +431,7 @@ huffman_error huffman_context_base::compute_tree_from_histo()
// binary search to achieve the optimum encoding
uint32_t lowerweight = 0;
uint32_t upperweight = sdatacount * 2;
- while (1)
+ while (true)
{
// build a tree using the current weight
uint32_t curweight = (upperweight + lowerweight) / 2;
@@ -678,14 +678,6 @@ void huffman_context_base::build_lookup_table()
// 8-BIT ENCODER
//**************************************************************************
-//-------------------------------------------------
-// huffman_8bit_encoder - constructor
-//-------------------------------------------------
-
-huffman_8bit_encoder::huffman_8bit_encoder()
-{
-}
-
//-------------------------------------------------
// encode - encode a full buffer
@@ -722,14 +714,6 @@ huffman_error huffman_8bit_encoder::encode(const uint8_t *source, uint32_t sleng
// 8-BIT DECODER
//**************************************************************************
-//-------------------------------------------------
-// huffman_8bit_decoder - constructor
-//-------------------------------------------------
-
-huffman_8bit_decoder::huffman_8bit_decoder()
-{
-}
-
/**
* @fn huffman_error huffman_8bit_decoder::decode(const uint8_t *source, uint32_t slength, uint8_t *dest, uint32_t dlength)
*