gendb: assorted cleanup