-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/65962/#review198861
-----------------------------------------------------------




src/launcher/default_executor.cpp
Line 729 (original), 729 (patched)
<https://reviews.apache.org/r/65962/#comment279113>

    We don't make use of `Owned` semantics here, and should just use
    
        Container* container = containers.at(taskId).get();


- Benjamin Bannier


On March 8, 2018, 3:07 a.m., Gaston Kleiman wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/65962/
> -----------------------------------------------------------
> 
> (Updated March 8, 2018, 3:07 a.m.)
> 
> 
> Review request for mesos and Joseph Wu.
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> `Owned` pointers are copied in multiple places of the default executor.
> This violates the semantic of owned pointers and works only because
> `Owned` is currently implemented with `shared_ptr`, it'd otherwise lead
> to double-freeing the pointers.
> 
> This patch changes those places to use references to the original
> `Owned` objects instead of copies.
> 
> 
> Diffs
> -----
> 
>   src/launcher/default_executor.cpp 906836f3b8e0af79d7c61f90fd8a95f193b26e84 
> 
> 
> Diff: https://reviews.apache.org/r/65962/diff/1/
> 
> 
> Testing
> -------
> 
> `sudo bin/mesos-tests.sh --gtest_filter="*Default*"` on GNU/Linux
> 
> 
> Thanks,
> 
> Gaston Kleiman
> 
>

Reply via email to