Use consistent/modern code formatting for pointers
The convention used by libjpeg:
type * variable;
is not very common anymore, because it looks too much like
multiplication. Some (particularly C++ programmers) prefer to tuck the
pointer symbol against the type:
type* variable;
to emphasize that a pointer to a type is effectively a new type.
However, this can also be confusing, since defining multiple variables
on the same line would not work properly:
type* variable1, variable2; /* Only variable1 is actually a
pointer. */
This commit reformats the entirety of the libjpeg-turbo code base so
that it uses the same code formatting convention for pointers that the
TurboJPEG API code uses:
type *variable1, *variable2;
This seems to be the most common convention among C programmers, and
it is the convention used by other codec libraries, such as libpng and
libtiff.
diff --git a/jidctflt.c b/jidctflt.c
index ed41fb1..68c521e 100644
--- a/jidctflt.c
+++ b/jidctflt.c
@@ -69,7 +69,7 @@
*/
GLOBAL(void)
-jpeg_idct_float (j_decompress_ptr cinfo, jpeg_component_info * compptr,
+jpeg_idct_float (j_decompress_ptr cinfo, jpeg_component_info *compptr,
JCOEFPTR coef_block,
JSAMPARRAY output_buf, JDIMENSION output_col)
{
@@ -77,8 +77,8 @@
FAST_FLOAT tmp10, tmp11, tmp12, tmp13;
FAST_FLOAT z5, z10, z11, z12, z13;
JCOEFPTR inptr;
- FLOAT_MULT_TYPE * quantptr;
- FAST_FLOAT * wsptr;
+ FLOAT_MULT_TYPE *quantptr;
+ FAST_FLOAT *wsptr;
JSAMPROW outptr;
JSAMPLE *range_limit = cinfo->sample_range_limit;
int ctr;