[ros-users] bug in operator<< for ros::Time

Troy Straszheim straszheim at willowgarage.com
Thu Sep 29 08:51:06 UTC 2011


2011/9/29 Peter Soetens <peter at thesourceworks.com>:
> On Thursday 29 September 2011 00:23:12 Troy Straszheim wrote:
>> Fixed in r15052, note this patch introduces a different bug:  what if my
>> fill character were '-' before the call to operator<<,  or if field width
>> were 17.  boost io state savers to the rescue...
>
> The field width is only kept for the next insertion in the stream and then
> cleared again. Only the fill character permanently modifies the 'os' object in
> the code below.
>

Okay, so just the fill character.  Just sharing the state saver trick.



More information about the ros-users mailing list