Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 344516 - GC with Transform crashes when rendering TextLayout with strikeout and selection
Summary: GC with Transform crashes when rendering TextLayout with strikeout and selection
Status: RESOLVED FIXED
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.1   Edit
Hardware: PC Windows 7
: P3 critical (vote)
Target Milestone: 3.7 RC1   Edit
Assignee: Felipe Heidrich CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-02 20:46 EDT by Hugo Corbucci CLA
Modified: 2011-05-04 16:13 EDT (History)
2 users (show)

See Also:
Silenio_Quarti: review+


Attachments
Snippet to reproduce the bug (1.73 KB, text/plain)
2011-05-02 20:48 EDT, Hugo Corbucci CLA
no flags Details
Patch (760 bytes, patch)
2011-05-04 15:09 EDT, Felipe Heidrich CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Hugo Corbucci CLA 2011-05-02 20:46:44 EDT
Build Identifier: 20110218-0911

On Windows (XP, Vista and 7), when trying to render a TextLayout with strikeout style and a selection on this style, the GC with a transform crashes the JVM with the following error:

#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x09d01f00, pid=3116, tid=2340
#
# JRE version: 6.0_25-b06
# Java VM: Java HotSpot(TM) Client VM (20.0-b11 mixed mode, sharing windows-x86 )
# Problematic frame:
# C  0x09d01f00

Apparently any transform will cause the problem, even if an empty transform. It doesn't happen to bold, italic, underline or any other style.


Reproducible: Always

Steps to Reproduce:
1. Create a TextLayout with some text and a strike out style.
2. On paint, set a transform on the GC.
3. Draw the text layout with selection containing the range which is struck out.
Comment 1 Hugo Corbucci CLA 2011-05-02 20:48:31 EDT
Created attachment 194547 [details]
Snippet to reproduce the bug
Comment 2 Felipe Heidrich CLA 2011-05-04 15:08:56 EDT
Thank you for the test case.
Comment 3 Felipe Heidrich CLA 2011-05-04 15:09:19 EDT
Created attachment 194755 [details]
Patch
Comment 4 Hugo Corbucci CLA 2011-05-04 15:21:54 EDT
(In reply to comment #3)
> Created attachment 194755 [details]
> Patch

Worked perfectly for us. Thank you!
Not changing the status since we're not familiar with the process but it looks RESOLVED to us.
Comment 5 Felipe Heidrich CLA 2011-05-04 16:13:54 EDT
Fixed in HEAD.