antirez/redis — pull request #417 by josephjang (2012-03-29 17:37:35+00:00)
Title: a memory leak with replication on two or more dbs

It occurs when two or more dbs are replicated and at least one of them is >db10.
I think every redis versions since 2.0.x are affected.

You can reproduce the problem with the following steps:

1. prepare for two redis instances.
- A redis instance listening port 6379
- A redis instance as slave of above

2. check and write down redis instance (master)'s memory usages by INFO command.

3. executes the following commands concurrently (i.e. from its own terminal).
term1 $ redis-cli -r 1000000 set foo bar
term2 $ redis-cli -n 15 -r 1000000 set foo bar

4. check redis instance (master)'s memory usage again when SET queries are finishes.
then you should confirm there's a memory leak.