Boost logo

Boost Users :

From: Elli Barasch (comptonsw_at_[hidden])
Date: 2007-12-18 16:56:32


Shared pointer question:
func(...)
{
    shared_pointer<foo> p;
             p = list<shared_pointer<foo> >.pop_front();
             p = list<shared_pointer<foo> >.pop_front();
}

Will this cause a memory leak? Do I need to do a delete in between, or
does the act of
reassignment cause the prior object to be dereferenced?

Thanks,
Elli Barasch


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net