]> git.pond.sub.org Git - empserver/commit
Verify table uid sanity more tightly
authorMarkus Armbruster <armbru@pond.sub.org>
Mon, 25 Apr 2011 07:34:11 +0000 (09:34 +0200)
committerMarkus Armbruster <armbru@pond.sub.org>
Sat, 25 Jun 2011 14:54:29 +0000 (16:54 +0200)
commitb30c83cd649e7e2b3f1622f6c63fcdad7079f1f7
tree22aae445eb718552e48c493206f6f41df7c66c4c
parentfbf5b78129bcfda39670612d180b84bd356575df
Verify table uid sanity more tightly

verify_row() refrains from rejecting zero uids, because some tables
may contain blank entries, with zero uid.

Change it to check only header sanity for entries that are not in use.
This filters out all legitimately blank entries.  Tighten up the uid
check.

For computing "in use", factor empobj_in_use() out of xdvisible().
Note that xdvisible()'s case EF_COUNTRY doesn't bother to check
nat_stat, because that's implied by what it does check.  It's not
implied in empobj_in_use(), so add it there.
include/empobj.h
src/lib/commands/xdump.c
src/lib/common/ef_verify.c
src/lib/common/empobj.c