X-Sharp / XSharpPublic

Public repository for the source code for the XSharp Compiler, Runtime, Project System and Tools.
Apache License 2.0
112 stars 38 forks source link

RP2 export to pdf crashes when the report includes text using the Cambria font #311

Open cpyrgas opened 4 years ago

cpyrgas commented 4 years ago

The attached very simple report has a single field with font set to "Cambria". When trying to export to pdf, RP2 crashes with a System.AccessViolationException in the readUShort() method of class rpTTFReader.

METHOD readUShort AS WORD
LOCAL s IS TTF_USHORT // swap bytes s:b[2] := SELF:pCurrent[1] <----- exception here s:b[1] := SELF:pCurrent[2] SELF:pCurrent += 2 RETURN s:w

RobertvanderHulst commented 4 years ago

Confirmed. This seems to work fine in VO strange enough.

cpyrgas commented 1 year ago

Closed by accident?

baramuse commented 1 year ago

It does not crash with Cambria on my machine. What version of Cambria do you have installed ?

cpyrgas commented 1 year ago

Can't reproduce it now either. But I'm sure it will resurface again, probably after a PC reboot etc

baramuse commented 1 year ago

We have a discussion on the XSharp forums : https://www.xsharp.eu/forum/public-3rdpart/3587-rp2-crash-when-using-specific-fonts-in-windows11-22h2 I'm trying to pinpoint it to the font parserbut now I can't make it crash on .net, so if you do have a font that makes it crash please report it back so I can give it a go :)

cpyrgas commented 1 year ago

OK, will do!