nostrdb

an unfairly fast embedded nostr database backed by lmdb
git clone git://jb55.com/nostrdb
Log | Files | Refs | README | LICENSE

commit 3f84a586c02b811c7d0cc1a05df021a2dc7bb01e
parent 90a664335a802304cb79ed4449dfdc095170e533
Author: William Casarin <jb55@jb55.com>
Date:   Mon, 24 Jul 2023 15:57:08 -0700

builder: allow note string funcs to work before finalization

We end up moving the strings table, but there's no reason for these to
not work before finalization.

Diffstat:
Mnostrdb.c | 1+
1 file changed, 1 insertion(+), 0 deletions(-)

diff --git a/nostrdb.c b/nostrdb.c @@ -52,6 +52,7 @@ int ndb_builder_init(struct ndb_builder *builder, unsigned char *buf, memset(note, 0, sizeof(*note)); builder->note_cur.p += sizeof(*note); + note->strings = builder->strings.start - buf; note->version = 1; return 1;