Fix GCC zip2exe/zlib z_crc_t type mismatch warning

git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@6437 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
anders_k 2014-02-03 19:23:46 +00:00
parent 4543f3f994
commit 469e1e26fd
2 changed files with 4 additions and 4 deletions

View file

@ -32,7 +32,7 @@
/***********************************************************************
* Return the next byte in the pseudo-random sequence
*/
static int decrypt_byte(unsigned long* pkeys, const unsigned long* pcrc_32_tab)
static int decrypt_byte(unsigned long* pkeys,const z_crc_t FAR *pcrc_32_tab)
{
unsigned temp; /* POTENTIAL BUG: temp*(temp^1) may overflow in an
* unpredictable manner on 16-bit systems; not a problem
@ -45,7 +45,7 @@ static int decrypt_byte(unsigned long* pkeys, const unsigned long* pcrc_32_tab)
/***********************************************************************
* Update the encryption keys with the next byte of plain text
*/
static int update_keys(unsigned long* pkeys,const unsigned long* pcrc_32_tab,int c)
static int update_keys(unsigned long* pkeys,const z_crc_t FAR *pcrc_32_tab,int c)
{
(*(pkeys+0)) = CRC32((*(pkeys+0)), c);
(*(pkeys+1)) += (*(pkeys+0)) & 0xff;
@ -62,7 +62,7 @@ static int update_keys(unsigned long* pkeys,const unsigned long* pcrc_32_tab,int
* Initialize the encryption keys and the random header according to
* the given password.
*/
static void init_keys(const char* passwd,unsigned long* pkeys,const unsigned long* pcrc_32_tab)
static void init_keys(const char* passwd,unsigned long* pkeys,const z_crc_t FAR *pcrc_32_tab)
{
*(pkeys+0) = 305419896L;
*(pkeys+1) = 591751049L;

View file

@ -150,7 +150,7 @@ typedef struct
int encrypted;
# ifndef NOUNCRYPT
unsigned long keys[3]; /* keys defining the pseudo-random sequence */
const unsigned long* pcrc_32_tab;
const z_crc_t FAR *pcrc_32_tab;
# endif
} unz_s;