Attached are proposed diffs to fix the various WAL-related problems I've
tracked down over the past few days. See summary I will post to
pghackers in a few minutes.
This is not ready to commit yet, because I still need to prepare some
kind of contrib utility to reset pg_control and pg_xlog --- that will
allow people to update existing 7.1beta installations without initdb,
not to mention being possibly useful in disaster recovery situations.
regards, tom lane