summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2011-11-10 21:03:44 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2011-11-10 21:04:10 -0800
commit696be14bcb4daef5280b425e297223c6ae530cb5 (patch)
treed17367cb2809ef8924054e4e0abf78ad0e4bf5ba
parent29972ebbb2409bcba87637069a7ad9a958b3325d (diff)
downloadxorg-lib-libXpm-696be14bcb4daef5280b425e297223c6ae530cb5.tar.gz
Assume C89 and just use const, not local Const macro
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--src/XpmI.h6
-rw-r--r--src/create.c8
-rw-r--r--src/scan.c2
3 files changed, 5 insertions, 11 deletions
diff --git a/src/XpmI.h b/src/XpmI.h
index e6885da..9690622 100644
--- a/src/XpmI.h
+++ b/src/XpmI.h
@@ -306,12 +306,6 @@ FUNC(xpm_znormalizeimagebits, void, (register unsigned char *bp,
#define ZINDEX1(x, y, img) ((y) * img->bytes_per_line) + ((x) >> 3)
#endif /* not AMIGA */
-#ifdef __STDC__
-#define Const const
-#else
-#define Const /**/
-#endif
-
#ifdef NEED_STRDUP
FUNC(xpmstrdup, char *, (char *s1));
#else
diff --git a/src/create.c b/src/create.c
index 00084d4..dc09370 100644
--- a/src/create.c
+++ b/src/create.c
@@ -219,7 +219,7 @@ typedef struct {
} CloseColor;
static int
-closeness_cmp(Const void *a, Const void *b)
+closeness_cmp(const void *a, const void *b)
{
CloseColor *x = (CloseColor *) a, *y = (CloseColor *) b;
@@ -1028,7 +1028,7 @@ LFUNC(_putbits, void, (register char *src, int dstoffset,
LFUNC(_XReverse_Bytes, int, (register unsigned char *bpt, register unsigned int nb));
-static unsigned char Const _reverse_byte[0x100] = {
+static unsigned char const _reverse_byte[0x100] = {
0x00, 0x80, 0x40, 0xc0, 0x20, 0xa0, 0x60, 0xe0,
0x10, 0x90, 0x50, 0xd0, 0x30, 0xb0, 0x70, 0xf0,
0x08, 0x88, 0x48, 0xc8, 0x28, 0xa8, 0x68, 0xe8,
@@ -1146,9 +1146,9 @@ xpm_znormalizeimagebits(
}
}
-static unsigned char Const _lomask[0x09] = {
+static unsigned char const _lomask[0x09] = {
0x00, 0x01, 0x03, 0x07, 0x0f, 0x1f, 0x3f, 0x7f, 0xff};
-static unsigned char Const _himask[0x09] = {
+static unsigned char const _himask[0x09] = {
0xff, 0xfe, 0xfc, 0xf8, 0xf0, 0xe0, 0xc0, 0x80, 0x00};
static void
diff --git a/src/scan.c b/src/scan.c
index 858f274..e51d1ab 100644
--- a/src/scan.c
+++ b/src/scan.c
@@ -589,7 +589,7 @@ ScanOtherColors(
* level.
*/
-static unsigned long Const low_bits_table[] = {
+static unsigned long const low_bits_table[] = {
0x00000000, 0x00000001, 0x00000003, 0x00000007,
0x0000000f, 0x0000001f, 0x0000003f, 0x0000007f,
0x000000ff, 0x000001ff, 0x000003ff, 0x000007ff,