Skip to content

Commit d1ff6a7

Browse files
committed
Use const reference for std::string
1 parent 5daa0db commit d1ff6a7

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

nodelet_topic_tools/include/nodelet_topic_tools/nodelet_lazy.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -232,7 +232,7 @@ class NodeletLazy: public nodelet::Nodelet
232232
*/
233233
template<class T> ros::Publisher
234234
advertise(ros::NodeHandle& nh,
235-
std::string topic, int queue_size, bool latch=false)
235+
const std::string& topic, int queue_size, bool latch=false)
236236
{
237237
boost::mutex::scoped_lock lock(connection_mutex_);
238238
ros::SubscriberStatusCallback connect_cb

0 commit comments

Comments
 (0)