engine: common: fix possible NULL dereference in LZSS_Compress
This commit is contained in:
parent
f995d055b5
commit
dd8c66d90e
1 changed files with 3 additions and 0 deletions
|
@ -390,6 +390,9 @@ byte *LZSS_Compress( byte *pInput, int inputLength, uint *pOutputSize )
|
|||
byte *pFinal = NULL;
|
||||
lzss_state_t state;
|
||||
|
||||
if( !pStart )
|
||||
return NULL;
|
||||
|
||||
memset( &state, 0, sizeof( state ));
|
||||
state.window_size = LZSS_WINDOW_SIZE;
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue