Fix incomplete teardown in Greenplum adapter