agmtlist_shutdown (repl5_agmtlist.c) had an illegal access defect.
Object ro is freed in objset_next_obj and next object is returned
if any. After ro is released, it was used to get agreement data.
This patch moves the location of objset_next_obj after the agreement
data is retrieved.