Re: cString operator= with same buffer

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Sascha Volkenandt wrote:
> On Sunday 20 November 2005 20:53, Jon Burgess wrote:
[ explaination of why the strstr example works deleted ]
> So, no unexpected behaviour here.

Yes, you're right. The intermeadiate buffer which is created avoids the 
problem. I confirmed this myself after sending the previous email.

> Like I mentioned before, I don't think all of this is necessary since the 
> normal ctor and the copy ctor cover all cases. 

I think something should be done to fix the "assign cString to itself" 
case, even though this is very unlikely. This does go wrong with the 
current code, even with the copy constructor added.

	Jon


[Index of Archives]     [Linux Media]     [Asterisk]     [DCCP]     [Netdev]     [Xorg]     [Util Linux NG]     [Xfree86]     [Big List of Linux Books]     [Fedora Users]     [Fedora Women]     [ALSA Devel]     [Linux USB]

  Powered by Linux