db: Fix erronous allocated size

Change-Id: I914c99ec58312a9e60dab22d95f98f2ee411537d
Signed-off-by: José Bollo <jose.bollo@open.eurogiciel.org>