[gs-bugs] [Bug 690617] New: If FixedPage.Resources is empty, null-ptr results in crash

bugs.ghostscript.com-bugzilla-daemon at ghostscript.com bugs.ghostscript.com-bugzilla-daemon at ghostscript.com
Fri Jul 10 07:25:32 PDT 2009


           Summary: If FixedPage.Resources is empty, null-ptr results in
           Product: GhostXPS
           Version: trunk
          Platform: PC
        OS/Version: Windows XP
            Status: NEW
          Severity: normal
          Priority: P4
         Component: General
        AssignedTo: tor.andersson at artifex.com
        ReportedBy: norbert.janssen at oce.com
         QAContact: gs-bugs at ghostscript.com

Send attached job (from MicroSoft list of handcrafted XPS test jobs) to GhostXPS
and it crashed because of a null-ptr being handed down to:
xps_resource_dictionary_has_transparency() and
in xps_parse_resource_dictionary().

in xpspage.c: add an extra check that xps_down(node) != 0

detecting transparency:
if ((!strcmp(xps_tag(node), "FixedPage.Resources")) && (xps_down(node) != 0))
    if (xps_resource_dictionary_has_transparency(ctx, xps_down(node)))

drawing contents:
if ((!strcmp(xps_tag(node), "FixedPage.Resources")) && (xps_down(node) != 0))
    if (xps_parse_resource_dictionary(ctx, xps_down(node)))

------- You are receiving this mail because: -------
You are the QA contact for the bug, or are watching the QA contact.

More information about the gs-bugs mailing list