Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

JSON.DEL makes redis to crash if empty path #76

Closed
KromDaniel opened this issue Jul 2, 2018 · 2 comments
Closed

JSON.DEL makes redis to crash if empty path #76

KromDaniel opened this issue Jul 2, 2018 · 2 comments

Comments

@KromDaniel
Copy link
Contributor

KromDaniel commented Jul 2, 2018

Hey,
Redis seems to crash with the empty command on JSON.DEL

Some environment information:

  • go-redis/redis (client driver)
  • Redis version redis_version:4.0.8, with rejson extension, running with ReJSON docker

Problem explained

I'm sending a bulk string to redis, with optional value as empty string and my redis crashes.
After debugging it a bit, this is the actual data being written to Redis:

*3
$8
JSON.DEL
$7
someKey
$0

It works (not crashing the redis) when I'm sending it with none empty string:

*3
$8
JSON.DEL
$7
someKey
$3
key

I'm debugging it my self now hopefully I'll open PR in the next few days

Thanks a lot

@itamarhaber
Copy link
Collaborator

Hello @KromDaniel

Thanks for finding, identifying and reporting the bug. Definitely smells ReJSON-ish to me. Need to reproduce and fix.

@github-actions
Copy link

Stale issue message

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants