Add cancellation support to util::Task.
Add memory management to util::Task.