Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

UFO crash #709

Closed
davelab6 opened this issue Aug 30, 2013 · 7 comments
Closed

UFO crash #709

davelab6 opened this issue Aug 30, 2013 · 7 comments
Assignees

Comments

@davelab6
Copy link
Member

@vernnobile says in https://gist.github.com/davelab6/6362877 that,

The UFO files created now seem to have a major issue. Re-opening them in fontforge on gnu+linux causes fontforge to crash. However this seems to be a fault now with all UFOs now being created by fontforge.

Program received signal SIGSEGV, Segmentation fault.
XMLEntryToPython (doc=0x889dd0, entry=0x0) at ufo.c:972
972     if ( xmlStrcmp(entry->name,(const xmlChar *) "true")==0 ) {
(gdb) bt
#0  XMLEntryToPython (doc=0x889dd0, entry=0x0) at ufo.c:972
#1  0x00007ffff3e8c4d8 in LibToPython (doc=doc@entry=0x889dd0, 
    dict=<error reading variable: Unhandled dwarf expression opcode 0xfa>) at ufo.c:956
#2  0x00007ffff3e8e213 in _UFOLoadGlyph (doc=0x889dd0, 
    glifname=glifname@entry=0x844c40 "/home/vern/gitHub/topmarks/Regular/src/Kodato-Regular.ufo/glyphs/_notdef.glif") at ufo.c:1365
#3  0x00007ffff3e90235 in UFOLoadGlyph (
    glifname=0x844c40 "/home/vern/gitHub/topmarks/Regular/src/Kodato-Regular.ufo/glyphs/_notdef.glif")
    at ufo.c:1383
#4  UFOLoadGlyphs (
    glyphdir=0x809cf0 "/home/vern/gitHub/topmarks/Regular/src/Kodato-Regular.ufo/glyphs", sf=0x88d790)
    at ufo.c:1451
#5  SFReadUFO (
    basedir=basedir@entry=0x888c00 "/home/vern/gitHub/topmarks/Regular/src/Kodato-Regular.ufo/", 
    flags=flags@entry=0) at ufo.c:1953
#6  0x00007ffff3ddb96f in _ReadSplineFont (file=0x8683c0, file@entry=0x0, 
    filename=filename@entry=0x888c00 "/home/vern/gitHub/topmarks/Regular/src/Kodato-Regular.ufo/", 
    openflags=openflags@entry=0) at splinefont.c:1045
#7  0x00007ffff3ddc54c in ReadSplineFont (
    filename=filename@entry=0x888c00 "/home/vern/gitHub/topmarks/Regular/src/Kodato-Regular.ufo/", 
    openflags=openflags@entry=0) at splinefont.c:1248
#8  0x00007ffff3ddc650 in LoadSplineFont (
    filename=0x888c00 "/home/vern/gitHub/topmarks/Regular/src/Kodato-Regular.ufo/", 
    openflags=openflags@entry=0) at splinefont.c:1321
#9  0x00007ffff3c9f88c in ViewPostScriptFont (filename=<optimized out>, openflags=0)
    at fontviewbase.c:1319
#10 0x00007ffff42e5768 in MenuOpen (gw=gw@entry=0x0, UNUSED_mi=UNUSED_mi@entry=0x0, 
    UNUSED_e=UNUSED_e@entry=0x0) at fontview.c:1024
#11 0x00007ffff437d18c in fontforge_main (argc=1, argv=<optimized out>) at startui.c:1258
#12 0x00007ffff1e85ead in __libc_start_main () from /lib/x86_64-linux-gnu/libc.so.6
#13 0x0000000000400961 in _start ()
@ghost ghost assigned monkeyiq Aug 30, 2013
@vernnobile
Copy link
Contributor

i can confirm that the issue seems to be gnuLinux only. Not able to reproduce on OSX build latest (30_0421). Will test some more on other linux distros.

@vernnobile
Copy link
Contributor

I have reproduced this crash on a fresh install of Debian 7. Fontforge build from git commit e2d6035

Generate UFO file, then open that UFO file. It does seem that not all UFOs cause a crash, but UFO created by older builds of Fontforge are not causing crashes.

These UFOs will also not open in Robofont on OSX (see screenshot of Robofont error below)

screen shot 2013-08-30 at 07 59 55

backtrace;

Program received signal SIGSEGV, Segmentation fault.
XMLEntryToPython (doc=0x97f6b0, entry=0x0) at ufo.c:972
972     if ( xmlStrcmp(entry->name,(const xmlChar *) "true")==0 ) {
(gdb) bt
#0  XMLEntryToPython (doc=0x97f6b0, entry=0x0) at ufo.c:972
#1  0x00007ffff3e8d4d8 in LibToPython (doc=doc@entry=0x97f6b0, 
    dict=<error reading variable: Unhandled dwarf expression opcode 0xfa>) at ufo.c:956
#2  0x00007ffff3e8f213 in _UFOLoadGlyph (doc=0x97f6b0, 
    glifname=glifname@entry=0x9658f0 "/home/vern/gitHub/topmarks/Bold/src/Topmarks-Bold-2.ufo/glyphs/e.glif")
    at ufo.c:1365
#3  0x00007ffff3e91235 in UFOLoadGlyph (
    glifname=0x9658f0 "/home/vern/gitHub/topmarks/Bold/src/Topmarks-Bold-2.ufo/glyphs/e.glif") at ufo.c:1383
#4  UFOLoadGlyphs (glyphdir=0x840480 "/home/vern/gitHub/topmarks/Bold/src/Topmarks-Bold-2.ufo/glyphs", 
    sf=0x8b3240) at ufo.c:1451
#5  SFReadUFO (basedir=basedir@entry=0x891870 "/home/vern/gitHub/topmarks/Bold/src/Topmarks-Bold-2.ufo/", 
    flags=flags@entry=0) at ufo.c:1953
#6  0x00007ffff3ddc96f in _ReadSplineFont (file=0x8a8e40, file@entry=0x0, 
    filename=filename@entry=0x891870 "/home/vern/gitHub/topmarks/Bold/src/Topmarks-Bold-2.ufo/", 
    openflags=openflags@entry=0) at splinefont.c:1045
#7  0x00007ffff3ddd54c in ReadSplineFont (
    filename=filename@entry=0x891870 "/home/vern/gitHub/topmarks/Bold/src/Topmarks-Bold-2.ufo/", 
    openflags=openflags@entry=0) at splinefont.c:1248
#8  0x00007ffff3ddd650 in LoadSplineFont (
    filename=0x891870 "/home/vern/gitHub/topmarks/Bold/src/Topmarks-Bold-2.ufo/", openflags=openflags@entry=0)
---Type <return> to continue, or q <return> to quit---
    at splinefont.c:1321
#9  0x00007ffff3ca088c in ViewPostScriptFont (filename=<optimized out>, openflags=0) at fontviewbase.c:1319
#10 0x00007ffff42e6768 in MenuOpen (gw=gw@entry=0x0, UNUSED_mi=UNUSED_mi@entry=0x0, 
    UNUSED_e=UNUSED_e@entry=0x0) at fontview.c:1024
#11 0x00007ffff437e18c in fontforge_main (argc=1, argv=<optimized out>) at startui.c:1258
#12 0x00007ffff1e86ead in __libc_start_main () from /lib/x86_64-linux-gnu/libc.so.6
#13 0x0000000000400961 in _start ()```

@frank-trampe
Copy link
Contributor

Saving as sfd, then saving as ufo, and then re-opening works for me at c9c03b4 on Linux Mint 13 on amd64 (using Rokkit from another bug report). Can somebody post a sample corrupt file?

@davelab6
Copy link
Member Author

@vernnobile please post a sample file on gist for @frank-trampe

@vernnobile
Copy link
Contributor

Hmm. I have a ufo file that was first created by Robofont, then openend in Fontforge, then saved as a UFO from fontforge. It can be openend OK in FontForge but will not open in Robofont (see screenshot)
Posted the sfd on gist --> https://gist.github.com/vernnobile/7709172

screen shot 2013-11-29 at 9 28 31 am

Also, although FontForge does open the UFO it gives the following warnings;
screen shot 2013-11-29 at 10 31 00 am

@frank-trampe
Copy link
Contributor

We've made some stability and some interchange enhancements. Can @vernnobile try this on current master?

@vernnobile
Copy link
Contributor

Frank!
OK, so i tested the corrupt sfd i posted at https://gist.github.com/vernnobile/7709172
The file opens fine, and not even any warnings. Good work & thanks :)

@ghost ghost assigned frank-trampe Dec 8, 2013
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants