EVALSHA is now case insensitive.

EVALSHA used to crash if the SHA1 was not lowercase (Issue #783).
Fixed using a case insensitive dictionary type for the sha -> script
map used for replication of scripts.
This commit is contained in:
antirez
2012-11-22 15:50:00 +01:00
parent de00a5a092
commit 9120275dc9
4 changed files with 18 additions and 2 deletions

View File

@ -47,6 +47,10 @@ start_server {tags {"scripting"}} {
r evalsha 9bd632c7d33e571e9f24556ebed26c3479a87129 0
} {myval}
test {EVALSHA - Can we call a SHA1 in uppercase?} {
r evalsha 9BD632C7D33E571E9F24556EBED26C3479A87129 0
} {myval}
test {EVALSHA - Do we get an error on invalid SHA1?} {
catch {r evalsha NotValidShaSUM 0} e
set _ $e