Re: std::string::assign

2012-08-28 Thread Richard Kojedzinszky
Date: Tue, 28 Aug 2012 13:56:46 +0100 From: Jonathan Wakely To: Richard Kojedzinszky Cc: gcc-bugs@gcc.gnu.org Subject: Re: std::string::assign Re: http://gcc.gnu.org/ml/gcc-bugs/2012-08/msg01843.html Hi, the gcc-bugs mailing list is for automated mails from our bug database, http://gcc.gn

std::string::assign

2012-08-28 Thread Richard Kojedzinszky
Dear All, I've a strange bug, I've attached a small source which shows my issue. So, I am trying to assign a string containing an embedded \0 in it. You will find that in test() I use std::string::assign to do this, but in two cases the results are different. Please see the output of the att