Fop
  1. Fop
  2. FOP-1440

use of rgb-icc inside of simple-page-master results in null pointer exeption

    Details

    • Type: Bug Bug
    • Status: Closed
    • Resolution: Fixed
    • Affects Version/s: 0.94
    • Fix Version/s: None
    • Component/s: general
    • Labels:
      None
    • Environment:
      Operating System: Linux
      Platform: All
    • External issue ID:
      43705

      Description

      Hello,

      i think fop should parse and initialize <fo:declarations> before
      <fo:layout-master-set> to fix this issue.

      I'll attach the fo-document.

      I havn't tested trunk on this so this might be fixed already.
      Is there a binary snapshot anywhere?

      Steps to reproduce:

      fop demo.fo demo.pdf

      Outputs on my System:

      Oct 26, 2007 3:17:46 PM org.apache.fop.cli.Main startFOP
      SEVERE: Exception
      java.lang.NullPointerException
      at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:168)
      at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:115)
      at org.apache.fop.cli.Main.startFOP(Main.java:166)
      at org.apache.fop.cli.Main.main(Main.java:197)

      ---------

      java.lang.NullPointerException
      at org.apache.fop.fo.expr.ICCColorFunction.eval(ICCColorFunction.java:49)
      at
      org.apache.fop.fo.expr.PropertyParser.parsePrimaryExpr(PropertyParser.java:319)
      at
      org.apache.fop.fo.expr.PropertyParser.parseUnaryExpr(PropertyParser.java:211)
      at
      org.apache.fop.fo.expr.PropertyParser.parseMultiplicativeExpr(PropertyParser.java:176)
      at
      org.apache.fop.fo.expr.PropertyParser.parseAdditiveExpr(PropertyParser.java:150)
      at
      org.apache.fop.fo.expr.PropertyParser.parseProperty(PropertyParser.java:124)
      at org.apache.fop.fo.expr.PropertyParser.parse(PropertyParser.java:90)
      at org.apache.fop.fo.properties.PropertyMaker.make(PropertyMaker.java:437)
      at
      org.apache.fop.fo.PropertyList.convertAttributeToProperty(PropertyList.java:411)
      at org.apache.fop.fo.PropertyList.addAttributesToList(PropertyList.java:313)
      at org.apache.fop.fo.FObj.processNode(FObj.java:121)
      at
      org.apache.fop.fo.FOTreeBuilder$MainFOHandler.startElement(FOTreeBuilder.java:320)
      at org.apache.fop.fo.FOTreeBuilder.startElement(FOTreeBuilder.java:185)
      at
      org.apache.xalan.transformer.TransformerIdentityImpl.startElement(TransformerIdentityImpl.java:1072)
      at org.apache.xerces.parsers.AbstractSAXParser.startElement(Unknown Source)
      at
      org.apache.xerces.parsers.AbstractXMLDocumentParser.emptyElement(Unknown Source)
      at
      org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source)
      at
      org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown
      Source)
      at
      org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
      at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
      at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
      at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
      at
      org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:484)
      at org.apache.fop.cli.InputHandler.transformTo(InputHandler.java:165)
      at org.apache.fop.cli.InputHandler.renderTo(InputHandler.java:115)
      at org.apache.fop.cli.Main.startFOP(Main.java:166)
      at org.apache.fop.cli.Main.main(Main.java:197)

      1. demo.fo
        0.6 kB
        Marc - A. Dahlhaus

        Activity

        Marc - A. Dahlhaus created issue -
        Hide
        Marc - A. Dahlhaus added a comment -
        Show
        Marc - A. Dahlhaus added a comment - The icc-profile used can be downloaded here: http://www.eci.org/eci/downloads/ECI-de/iccprofile_der_eci/ECI_Offset_2007.zip
        Hide
        Marc - A. Dahlhaus added a comment -

        Attachment demo.fo has been added with description: My test fo-document

        Show
        Marc - A. Dahlhaus added a comment - Attachment demo.fo has been added with description: My test fo-document
        Hide
        Andreas L. Delmelle added a comment -

        (In reply to comment #0)

        Sorry for the late reply.
        >
        > i think fop should parse and initialize <fo:declarations> before
        > <fo:layout-master-set> to fix this issue.

        Not really that simple, I'm afraid.

        >
        > I'll attach the fo-document.
        >
        > I havn't tested trunk on this so this might be fixed already.

        The issue still exists (or rather: existed) in FOP Trunk, but has now been 'fixed', in the sense that I
        interpret this case to be one where 'the color-profile is not available', and so the processor should
        revert to the sRGB fallback specified by the first three arguments.
        see: http://www.w3.org/TR/xsl11/#fo_color-profile

        > Is there a binary snapshot anywhere?

        Unfortunately not, but downloading the trunk source code and building with Ant is really very simple.
        See: http://xmlgraphics.apache.org/fop/trunk/compiling.html

        and for the fix: http://svn.apache.org/viewvc?rev=617989&view=rev

        Thanks for reporting!

        Show
        Andreas L. Delmelle added a comment - (In reply to comment #0) Sorry for the late reply. > > i think fop should parse and initialize <fo:declarations> before > <fo:layout-master-set> to fix this issue. Not really that simple, I'm afraid. > > I'll attach the fo-document. > > I havn't tested trunk on this so this might be fixed already. The issue still exists (or rather: existed) in FOP Trunk, but has now been 'fixed', in the sense that I interpret this case to be one where 'the color-profile is not available', and so the processor should revert to the sRGB fallback specified by the first three arguments. see: http://www.w3.org/TR/xsl11/#fo_color-profile > Is there a binary snapshot anywhere? Unfortunately not, but downloading the trunk source code and building with Ant is really very simple. See: http://xmlgraphics.apache.org/fop/trunk/compiling.html and for the fix: http://svn.apache.org/viewvc?rev=617989&view=rev Thanks for reporting!
        Hide
        Glenn Adams added a comment -

        batch transition pre-FOP1.0 resolved+fixed bugs to closed+fixed

        Show
        Glenn Adams added a comment - batch transition pre-FOP1.0 resolved+fixed bugs to closed+fixed

          People

          • Assignee:
            fop-dev
            Reporter:
            Marc - A. Dahlhaus
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development