Changeset 176474 in webkit
- Timestamp:
- Nov 21, 2014, 3:10:59 PM (12 years ago)
- Location:
- trunk/Source/WebKit2
- Files:
-
- 2 edited
-
ChangeLog (modified) (1 diff)
-
Shared/WebCoreArgumentCoders.cpp (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/WebKit2/ChangeLog
r176463 r176474 1 2014-11-21 Tim Horton <timothy_horton@apple.com> 2 3 Crashes while encoding a TextIndicator with no contentImageWithHighlight 4 https://bugs.webkit.org/show_bug.cgi?id=138984 5 <rdar://problem/19063717> 6 7 Reviewed by Sam Weinig. 8 9 * Shared/WebCoreArgumentCoders.cpp: 10 (IPC::ArgumentCoder<TextIndicatorData>::encode): 11 (IPC::ArgumentCoder<TextIndicatorData>::decode): 12 encodeImage doesn't deal with null images, so handle that case gracefully. 13 1 14 2014-11-21 Tim Horton <timothy_horton@apple.com> 2 15 -
trunk/Source/WebKit2/Shared/WebCoreArgumentCoders.cpp
r176462 r176474 1969 1969 encoder << textIndicatorData.contentImageScaleFactor; 1970 1970 encoder.encodeEnum(textIndicatorData.presentationTransition); 1971 encodeImage(encoder, textIndicatorData.contentImage.get()); 1972 encodeImage(encoder, textIndicatorData.contentImageWithHighlight.get()); 1971 1972 bool hasImage = textIndicatorData.contentImage; 1973 encoder << hasImage; 1974 if (hasImage) 1975 encodeImage(encoder, textIndicatorData.contentImage.get()); 1976 1977 bool hasImageWithHighlight = textIndicatorData.contentImageWithHighlight; 1978 encoder << hasImageWithHighlight; 1979 if (hasImageWithHighlight) 1980 encodeImage(encoder, textIndicatorData.contentImageWithHighlight.get()); 1973 1981 } 1974 1982 … … 1990 1998 return false; 1991 1999 1992 if (!decodeImage(decoder, textIndicatorData.contentImage)) 1993 return false; 1994 1995 if (!decodeImage(decoder, textIndicatorData.contentImageWithHighlight)) 2000 bool hasImage; 2001 if (!decoder.decode(hasImage)) 2002 return false; 2003 if (hasImage && !decodeImage(decoder, textIndicatorData.contentImage)) 2004 return false; 2005 2006 bool hasImageWithHighlight; 2007 if (!decoder.decode(hasImageWithHighlight)) 2008 return false; 2009 if (hasImageWithHighlight && !decodeImage(decoder, textIndicatorData.contentImageWithHighlight)) 1996 2010 return false; 1997 2011
Note:
See TracChangeset
for help on using the changeset viewer.