support modern berkeley db
fixed invalid lvalue in increment