{"action":"created","issue":{"url":"https://api.github.com/repos/fontforge/fontforge/issues/2390","labels_url":"https://api.github.com/repos/fontforge/fontforge/issues/2390/labels{/name}","comments_url":"https://api.github.com/repos/fontforge/fontforge/issues/2390/comments","events_url":"https://api.github.com/repos/fontforge/fontforge/issues/2390/events","html_url":"https://github.com/fontforge/fontforge/issues/2390","id":90662500,"number":2390,"title":"Crash when using Spiro mode","user":{"login":"jtanx","id":5137410,"avatar_url":"https://avatars.githubusercontent.com/u/5137410?v=3","gravatar_id":"","url":"https://api.github.com/users/jtanx","html_url":"https://github.com/jtanx","followers_url":"https://api.github.com/users/jtanx/followers","following_url":"https://api.github.com/users/jtanx/following{/other_user}","gists_url":"https://api.github.com/users/jtanx/gists{/gist_id}","starred_url":"https://api.github.com/users/jtanx/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jtanx/subscriptions","organizations_url":"https://api.github.com/users/jtanx/orgs","repos_url":"https://api.github.com/users/jtanx/repos","events_url":"https://api.github.com/users/jtanx/events{/privacy}","received_events_url":"https://api.github.com/users/jtanx/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/fontforge/fontforge/labels/I-bug","name":"I-bug","color":"fc2929"},{"url":"https://api.github.com/repos/fontforge/fontforge/labels/I-crash","name":"I-crash","color":"e10c02"},{"url":"https://api.github.com/repos/fontforge/fontforge/labels/spurious","name":"spurious","color":"e6e6e6"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-06-24T12:31:59Z","updated_at":"2015-07-06T07:37:16Z","closed_at":null,"body":"If you add enough points in Spiro mode it will eventually crash. The warnings box says `Spiros did not converge`. I think it's a use-after-free issue but I don't know the exact origin of where this is ocurring.\r\n\r\n~~~~~\r\n==20620== Invalid read of size 8\r\n==20620==    at 0x4EE77FA: CVInfoDrawText (charview.c:4086)\r\n==20620==    by 0x4EE80CF: CVInfoDraw (charview.c:4147)\r\n==20620==    by 0x4F22273: CVMouseDownSpiroPoint (cvaddpoints.c:408)\r\n==20620==    by 0x4F223C0: CVMouseDownPoint (cvaddpoints.c:454)\r\n==20620==    by 0x4EEB72F: CVMouseDown (charview.c:5024)\r\n==20620==    by 0x4EEEBE2: v_e_h (charview.c:5735)\r\n==20620==    by 0x6135232: _GWidget_Container_eh (gcontainer.c:403)\r\n==20620==    by 0x61B3163: dispatchEvent (gxdraw.c:3296)\r\n==20620==    by 0x61B36FB: GXDrawEventLoop (gxdraw.c:3404)\r\n==20620==    by 0x6139A7A: GDrawEventLoop (gdraw.c:791)\r\n==20620==    by 0x50F3872: fontforge_main (startui.c:1382)\r\n==20620==    by 0x4007DC: main (main.c:39)\r\n==20620==  Address 0xfdcfbf0 is 192 bytes inside a block of size 240 free'd\r\n~~~~\r\n\r\nI had a backtrace for this but I lost it and it seems to be somewhat difficult to reproduce.\r\n\r\n--------\r\n\r\nThis one may be a separate crash (after deleting some points, `spline->to` is NULL). This one seems more reproducible - e.g. make some points, delete some in-between then try to add another point.\r\n~~~~\r\n#0  0x00007ffff78c4ed3 in CVClearSel (cv=0x905870) at cvpointer.c:162\r\n#1  0x00007ffff78c792f in CVMouseDownPointer (cv=0x905870, fs=0x7fffffffbb30, \r\n    event=0x7fffffffbdc0) at cvpointer.c:664\r\n#2  0x00007ffff784d5e7 in CVMouseDown (cv=0x905870, event=0x7fffffffbdc0)\r\n    at charview.c:4983\r\n#3  0x00007ffff7850be3 in v_e_h (gw=0x964c70, event=0x7fffffffbdc0)\r\n    at charview.c:5735\r\n#4  0x00007ffff683b233 in _GWidget_Container_eh (gw=0x964c70, \r\n    event=0x7fffffffbdc0) at gcontainer.c:403\r\n#5  0x00007ffff68b9164 in dispatchEvent (gdisp=0x69acc0, event=0x7fffffffbf70)\r\n    at gxdraw.c:3296\r\n#6  0x00007ffff68b96fc in GXDrawEventLoop (gd=0x69acc0) at gxdraw.c:3404\r\n#7  0x00007ffff683fa7b in GDrawEventLoop (gdisp=0x69acc0) at gdraw.c:791\r\n#8  0x00007ffff7a55873 in fontforge_main (argc=1, argv=0x7fffffffe2a8)\r\n    at startui.c:1382\r\n#9  0x00000000004007dd in main (argc=1, argv=0x7fffffffe2a8) at main.c:39\r\n~~~~"},"comment":{"url":"https://api.github.com/repos/fontforge/fontforge/issues/comments/118758198","html_url":"https://github.com/fontforge/fontforge/issues/2390#issuecomment-118758198","issue_url":"https://api.github.com/repos/fontforge/fontforge/issues/2390","id":118758198,"user":{"login":"ctrlcctrlv","id":838783,"avatar_url":"https://avatars.githubusercontent.com/u/838783?v=3","gravatar_id":"","url":"https://api.github.com/users/ctrlcctrlv","html_url":"https://github.com/ctrlcctrlv","followers_url":"https://api.github.com/users/ctrlcctrlv/followers","following_url":"https://api.github.com/users/ctrlcctrlv/following{/other_user}","gists_url":"https://api.github.com/users/ctrlcctrlv/gists{/gist_id}","starred_url":"https://api.github.com/users/ctrlcctrlv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ctrlcctrlv/subscriptions","organizations_url":"https://api.github.com/users/ctrlcctrlv/orgs","repos_url":"https://api.github.com/users/ctrlcctrlv/repos","events_url":"https://api.github.com/users/ctrlcctrlv/events{/privacy}","received_events_url":"https://api.github.com/users/ctrlcctrlv/received_events","type":"User","site_admin":false},"created_at":"2015-07-06T07:37:16Z","updated_at":"2015-07-06T07:37:16Z","body":"Please fix Spiro mode. It is so frustrating and crashes so often.\r\n\r\nI should be able to add/remove control points without fontforge segfaulting. I should be able to *easily* change the type of control point I put down, not the current buggy system (right click, \"Get Info\", change type, \"Next >\", \"Cancel\" because \"OK\" doesn't work to close the dialog...)\r\n\r\nThe original author seems to have moved on and abandoned this project, leaving only enthusiastic people like @davelab6 who are good at web design and Mac stuff but will never get around to fixing the source code...\r\n\r\nTherefore I pledge $150 in Bitcoin (currently 0.55BTC) to this issue. Also I would appreciate if the fixing author looks into my other issue #2406 , they are probably related. :)\r\n\r\nUsers of FontForge attempting to draw \"S\" glyphs around the world will thank you.\r\n\r\n![S](https://0x0.st/7D.png)"}}