# HG changeset patch # User reimar # Date 1351622257 0 # Node ID 9e06c2e4844e8d3b9323f9db6a105b9a81f4dbcd # Parent 4d0dda47f203810cb52cf84d1ff586f9371e0e92 Fix off-by-one error in range check. diff -r 4d0dda47f203 -r 9e06c2e4844e input/input.c --- a/input/input.c Tue Oct 30 18:23:01 2012 +0000 +++ b/input/input.c Tue Oct 30 18:37:37 2012 +0000 @@ -1170,7 +1170,7 @@ break; } if(j == num_key_down) { // key was not in the down keys : add it - if(num_key_down > MP_MAX_KEY_DOWN) { + if(num_key_down >= MP_MAX_KEY_DOWN) { mp_msg(MSGT_INPUT,MSGL_ERR,MSGTR_INPUT_INPUT_Err2ManyKeyDowns); return NULL; }