Added finalizer to process wrapper