Fixed memory leak in replicatedmap where records for removed entry were ...

...still referenced

Please do not yet merge it, need to find out if it is really resolving the problem!