Unsubscribing uisng shutdown()
I have a vector of subscribers and each subscriber has same callback function. When i try to clear the vector , code hangs indefinitely. So is there a way to unsubscribe or a way to deallocate the alloted memory.. beside the method mentioned above. I have also tried uisng ros::Subscriber::shutdown to unsubscribe an element of vector and still my code hangs...