You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@uima.apache.org by "Thomas Hampp (JIRA)" <ui...@incubator.apache.org> on 2009/07/21 16:37:14 UTC

[jira] Created: (UIMA-1446) org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception

org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception
----------------------------------------------------------------------------------------------------

                 Key: UIMA-1446
                 URL: https://issues.apache.org/jira/browse/UIMA-1446
             Project: UIMA
          Issue Type: Bug
          Components: Sandbox-SimpleServer
            Reporter: Thomas Hampp


in org.apache.uima.simpleserver.config.impl.SimpleFilterImpl

  private final boolean match(Stack<String> stack, FeatureStructure fs) {
   ...
fs can be null (if a non-leave feature in the feature path is null) but that is not checked for.

Suggested fix:
  private final boolean match(Stack<String> stack, FeatureStructure fs) {
	if (fs == null) {
	    return (this.getCondition().getConditionType() == FilterOp.NULL);
	}
	if (stack.isEmpty()) {
        ...


-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Assigned: (UIMA-1446) org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception

Posted by "Thilo Goetz (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1446?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thilo Goetz reassigned UIMA-1446:
---------------------------------

    Assignee: Thilo Goetz

> org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception
> ----------------------------------------------------------------------------------------------------
>
>                 Key: UIMA-1446
>                 URL: https://issues.apache.org/jira/browse/UIMA-1446
>             Project: UIMA
>          Issue Type: Bug
>          Components: Sandbox-SimpleServer
>            Reporter: Thomas Hampp
>            Assignee: Thilo Goetz
>
> in org.apache.uima.simpleserver.config.impl.SimpleFilterImpl
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
>    ...
> fs can be null (if a non-leave feature in the feature path is null) but that is not checked for.
> Suggested fix:
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
> 	if (fs == null) {
> 	    return (this.getCondition().getConditionType() == FilterOp.NULL);
> 	}
> 	if (stack.isEmpty()) {
>         ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (UIMA-1446) org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception

Posted by "Thilo Goetz (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1446?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thilo Goetz closed UIMA-1446.
-----------------------------

    Resolution: Fixed

Fixed bug (slightly differently than suggested).  Added a bunch of test cases.  Added reference output for all existing test cases.


> org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception
> ----------------------------------------------------------------------------------------------------
>
>                 Key: UIMA-1446
>                 URL: https://issues.apache.org/jira/browse/UIMA-1446
>             Project: UIMA
>          Issue Type: Bug
>          Components: Sandbox-SimpleServer
>    Affects Versions: 2.2.2S
>            Reporter: Thomas Hampp
>            Assignee: Thilo Goetz
>             Fix For: 2.3S
>
>
> in org.apache.uima.simpleserver.config.impl.SimpleFilterImpl
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
>    ...
> fs can be null (if a non-leave feature in the feature path is null) but that is not checked for.
> Suggested fix:
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
> 	if (fs == null) {
> 	    return (this.getCondition().getConditionType() == FilterOp.NULL);
> 	}
> 	if (stack.isEmpty()) {
>         ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (UIMA-1446) org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception

Posted by "Thilo Goetz (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1446?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thilo Goetz updated UIMA-1446:
------------------------------

    Affects Version/s: 2.2.2S
        Fix Version/s: 2.3S

> org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception
> ----------------------------------------------------------------------------------------------------
>
>                 Key: UIMA-1446
>                 URL: https://issues.apache.org/jira/browse/UIMA-1446
>             Project: UIMA
>          Issue Type: Bug
>          Components: Sandbox-SimpleServer
>    Affects Versions: 2.2.2S
>            Reporter: Thomas Hampp
>            Assignee: Thilo Goetz
>             Fix For: 2.3S
>
>
> in org.apache.uima.simpleserver.config.impl.SimpleFilterImpl
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
>    ...
> fs can be null (if a non-leave feature in the feature path is null) but that is not checked for.
> Suggested fix:
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
> 	if (fs == null) {
> 	    return (this.getCondition().getConditionType() == FilterOp.NULL);
> 	}
> 	if (stack.isEmpty()) {
>         ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Reopened: (UIMA-1446) org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception

Posted by "Thilo Goetz (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1446?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thilo Goetz reopened UIMA-1446:
-------------------------------


Test case output was generated with buggy jvm that doesn't honor {http://xml.apache.org/xslt}indent-amount.  Now the test cases fail with jvm that doesn't have this bug :(.  Apparently, this is a known issue for some Sun JVMs.


> org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception
> ----------------------------------------------------------------------------------------------------
>
>                 Key: UIMA-1446
>                 URL: https://issues.apache.org/jira/browse/UIMA-1446
>             Project: UIMA
>          Issue Type: Bug
>          Components: Sandbox-SimpleServer
>    Affects Versions: 2.2.2S
>            Reporter: Thomas Hampp
>            Assignee: Thilo Goetz
>             Fix For: 2.3S
>
>
> in org.apache.uima.simpleserver.config.impl.SimpleFilterImpl
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
>    ...
> fs can be null (if a non-leave feature in the feature path is null) but that is not checked for.
> Suggested fix:
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
> 	if (fs == null) {
> 	    return (this.getCondition().getConditionType() == FilterOp.NULL);
> 	}
> 	if (stack.isEmpty()) {
>         ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Closed: (UIMA-1446) org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception

Posted by "Thilo Goetz (JIRA)" <ui...@incubator.apache.org>.
     [ https://issues.apache.org/jira/browse/UIMA-1446?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Thilo Goetz closed UIMA-1446.
-----------------------------

    Resolution: Fixed

Test cases will fail with JVMs that have the bug I described in my last comment.


> org.apache.uima.simpleserver.config.impl.SimpleFilterImpl.match() can cause a null pointer exception
> ----------------------------------------------------------------------------------------------------
>
>                 Key: UIMA-1446
>                 URL: https://issues.apache.org/jira/browse/UIMA-1446
>             Project: UIMA
>          Issue Type: Bug
>          Components: Sandbox-SimpleServer
>    Affects Versions: 2.2.2S
>            Reporter: Thomas Hampp
>            Assignee: Thilo Goetz
>             Fix For: 2.3S
>
>
> in org.apache.uima.simpleserver.config.impl.SimpleFilterImpl
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
>    ...
> fs can be null (if a non-leave feature in the feature path is null) but that is not checked for.
> Suggested fix:
>   private final boolean match(Stack<String> stack, FeatureStructure fs) {
> 	if (fs == null) {
> 	    return (this.getCondition().getConditionType() == FilterOp.NULL);
> 	}
> 	if (stack.isEmpty()) {
>         ...

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.