engines/libzbc: add libzbc_finish_zone() helper function