pescan,readpe: Fix scopes.