The problem seems to be that there are negative coordinates being passed in to ProcPolySegment:
(gdb) p/x *(xSegment*)&((xPolySegmentReq *)0x2918e1c)[1] $11 = {x1 = 0x24, y1 = 0x10, x2 = 0xfffe, y2 = 0xffff}
I don't know who is supposed to catch this. Looking at the call sequence, nobody really makes sure that these values are in bounds.
The problem seems to be that there are negative coordinates being passed in to ProcPolySegment:
(gdb) p/x *(xSegment* )&((xPolySegmen tReq *)0x2918e1c)[1]
$11 = {x1 = 0x24, y1 = 0x10, x2 = 0xfffe, y2 = 0xffff}
I don't know who is supposed to catch this. Looking at the call sequence, nobody really makes sure that these values are in bounds.