Followon from a checkin I did yesterday to fix bugs 29521 and 29827 (a=jar); this part fixes an assertion that happened with empty form fields. r=kin

This commit is contained in:
sfraser%netscape.com 2000-03-02 19:36:15 +00:00
parent 03b765f70e
commit 19fa57d1f9

View File

@ -453,6 +453,9 @@ nsresult nsLinebreakConverter::ConvertStringLineBreaks(nsString& ioString,
NS_ASSERTION(aDestBreaks != eLinebreakAny, "Invalid parameter");
// nothing to do
if (ioString.Length() == 0) return NS_OK;
// we can't go messing with data we don't own
if (!ioString.mOwnsBuffer) return NS_ERROR_UNEXPECTED;