mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-09 11:25:00 +00:00
Fixing blocker bug 106474. Make nsAFlatString::GetReadableFragment() deal with a null buffer handles correctly. r=kin@netscape.com, sr=scc@mozilla.org
This commit is contained in:
parent
671634a107
commit
285c5940f6
@ -33,7 +33,9 @@ nsAFlatString::GetReadableFragment( const_fragment_type& aFragment, nsFragmentRe
|
||||
case kFragmentAt:
|
||||
{
|
||||
const buffer_handle_type* buffer = GetBufferHandle();
|
||||
NS_ASSERTION(buffer, "trouble: no buffer!");
|
||||
|
||||
if ( !buffer )
|
||||
return 0;
|
||||
|
||||
aFragment.mEnd = buffer->DataEnd();
|
||||
return (aFragment.mStart = buffer->DataStart()) + aOffset;
|
||||
|
@ -33,7 +33,9 @@ nsAFlatString::GetReadableFragment( const_fragment_type& aFragment, nsFragmentRe
|
||||
case kFragmentAt:
|
||||
{
|
||||
const buffer_handle_type* buffer = GetBufferHandle();
|
||||
NS_ASSERTION(buffer, "trouble: no buffer!");
|
||||
|
||||
if ( !buffer )
|
||||
return 0;
|
||||
|
||||
aFragment.mEnd = buffer->DataEnd();
|
||||
return (aFragment.mStart = buffer->DataStart()) + aOffset;
|
||||
|
Loading…
Reference in New Issue
Block a user