Clear existing format issue in the codebase
Fix the clang-format warnings on the existing codes.
Change-Id: I8e9e781b6f68f41a7fbd0a2116f6b35290d73dc8
diff --git a/aom_dsp/entcode.c b/aom_dsp/entcode.c
index 37aaa0e..7563f9f 100644
--- a/aom_dsp/entcode.c
+++ b/aom_dsp/entcode.c
@@ -23,10 +23,10 @@
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.*/
#ifdef HAVE_CONFIG_H
-#include "config.h"
+#include "./config.h"
#endif
-#include "entcode.h"
+#include "aom_dsp/entcode.h"
/*CDFs for uniform probability distributions of small sizes (2 through 16,
inclusive).*/
diff --git a/aom_dsp/entdec.c b/aom_dsp/entdec.c
index 4dcc0a1..a4e1d1d 100644
--- a/aom_dsp/entdec.c
+++ b/aom_dsp/entdec.c
@@ -23,12 +23,12 @@
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.*/
#ifdef HAVE_CONFIG_H
-#include "config.h"
+#include "./config.h"
#endif
-#include "entdec.h"
+#include "aom_dsp/entdec.h"
#if OD_ACCOUNTING
-#include "accounting.h"
+#include "./accounting.h"
#endif
/*A range decoder.
diff --git a/aom_dsp/entdec.h b/aom_dsp/entdec.h
index 110b9da..3c8e210 100644
--- a/aom_dsp/entdec.h
+++ b/aom_dsp/entdec.h
@@ -25,9 +25,9 @@
#if !defined(_entdec_H)
#define _entdec_H (1)
#include <limits.h>
-#include "entcode.h"
+#include "aom_dsp/entcode.h"
#if OD_ACCOUNTING
-#include "accounting.h"
+#include "./accounting.h"
#endif
#ifdef __cplusplus
diff --git a/aom_dsp/entenc.c b/aom_dsp/entenc.c
index 564086b..019c6fb 100644
--- a/aom_dsp/entenc.c
+++ b/aom_dsp/entenc.c
@@ -23,12 +23,12 @@
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.*/
#ifdef HAVE_CONFIG_H
-#include "config.h"
+#include "./config.h"
#endif
#include <stdlib.h>
#include <string.h>
-#include "entenc.h"
+#include "aom_dsp/entenc.h"
/*A range encoder.
See entdec.c and the references for implementation details \cite{Mar79,MNW98}.
@@ -419,8 +419,9 @@
ft1 = (int)(ft >> ftb) + 1;
od_ec_encode_cdf_q15(enc, (int)(fl >> ftb), OD_UNIFORM_CDF_Q15(ft1), ft1);
od_ec_enc_bits(enc, fl & (((uint32_t)1 << ftb) - 1), ftb);
- } else
+ } else {
od_ec_encode_cdf_q15(enc, (int)fl, OD_UNIFORM_CDF_Q15(ft), (int)ft);
+ }
}
/*Encodes a sequence of raw bits in the stream.
@@ -506,10 +507,10 @@
/*The first byte has yet to be output.*/
enc->low = (enc->low & ~((od_ec_window)mask << (16 + enc->cnt))) |
(od_ec_window)val << (16 + enc->cnt + shift);
- }
- /*The encoder hasn't even encoded _nbits of data yet.*/
- else
+ } else {
+ /*The encoder hasn't even encoded _nbits of data yet.*/
enc->error = -1;
+ }
}
#if OD_MEASURE_EC_OVERHEAD
diff --git a/aom_dsp/entenc.h b/aom_dsp/entenc.h
index 5df2092..396da2c 100644
--- a/aom_dsp/entenc.h
+++ b/aom_dsp/entenc.h
@@ -25,7 +25,7 @@
#if !defined(_entenc_H)
#define _entenc_H (1)
#include <stddef.h>
-#include "entcode.h"
+#include "aom_dsp/entcode.h"
#ifdef __cplusplus
extern "C" {
diff --git a/av1/common/odintrin.h b/av1/common/odintrin.h
index 0036535..73106df 100644
--- a/av1/common/odintrin.h
+++ b/av1/common/odintrin.h
@@ -66,7 +66,7 @@
#if defined(__GNUC__) && defined(__GNUC_MINOR__) && defined(__GNUC_PATCHLEVEL__)
#define OD_GNUC_PREREQ(maj, min, pat) \
((__GNUC__ << 16) + (__GNUC_MINOR__ << 8) + __GNUC_PATCHLEVEL__ >= \
- ((maj) << 16) + ((min) << 8) + pat)
+ ((maj) << 16) + ((min) << 8) + pat) // NOLINT
#else
#define OD_GNUC_PREREQ(maj, min, pat) (0)
#endif