Fix reading the database version mark. Sometimes there are several
version marks although there should be only one.
should help fix #35