Fix const warning in RLE getpix functions

This commit is contained in:
Sylvain Becker 2019-10-30 16:17:59 +01:00
parent 25d53a4475
commit f16e51068b
1 changed files with 4 additions and 4 deletions

View File

@ -1245,7 +1245,7 @@ getpix_8(const Uint8 * srcbuf)
static Uint32 static Uint32
getpix_16(const Uint8 * srcbuf) getpix_16(const Uint8 * srcbuf)
{ {
return *(Uint16 *) srcbuf; return *(const Uint16 *) srcbuf;
} }
static Uint32 static Uint32
@ -1259,12 +1259,12 @@ getpix_24(const Uint8 * srcbuf)
} }
static Uint32 static Uint32
getpix_32(Uint8 * srcbuf) getpix_32(const Uint8 * srcbuf)
{ {
return *(Uint32 *) srcbuf; return *(const Uint32 *) srcbuf;
} }
typedef Uint32(*getpix_func) (Uint8 *); typedef Uint32(*getpix_func) (const Uint8 *);
static const getpix_func getpixes[4] = { static const getpix_func getpixes[4] = {
getpix_8, getpix_16, getpix_24, getpix_32 getpix_8, getpix_16, getpix_24, getpix_32