ICEfaces
  1. ICEfaces
  2. ICE-11375

ice: components send value to a converter even when null, causing an NPE

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: EE-3.3.0.GA_P05
    • Fix Version/s: EE-3.3.0.GA_P06
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      Any

      Description

      When the value of our ice:inputText component is null and there's a converter specified for this component, a NullPointerException occurs because our component sends the value to the converter anyway, unlike h:inputText, which doesn't send it, avoiding this kind of issues.

        Activity

        Hide
        Arturo Zambrano added a comment -

        r52128: fix to avoid sending a null value to a converter, in order to prevent possible NullPointerException exceptions

        This fix is actually applied for all compat (ice:*) components.

        Looking at the mojarra source code, this behaviour is confirmed. The following two pages have discuss this fact in more detail.

        https://stackoverflow.com/questions/27048438/jsf-custom-converter-not-called-on-null-value
        https://stackoverflow.com/questions/35347001/jsf-converter-with-null-value

        Show
        Arturo Zambrano added a comment - r52128: fix to avoid sending a null value to a converter, in order to prevent possible NullPointerException exceptions This fix is actually applied for all compat (ice:*) components. Looking at the mojarra source code, this behaviour is confirmed. The following two pages have discuss this fact in more detail. https://stackoverflow.com/questions/27048438/jsf-custom-converter-not-called-on-null-value https://stackoverflow.com/questions/35347001/jsf-converter-with-null-value

          People

          • Assignee:
            Arturo Zambrano
            Reporter:
            Arturo Zambrano
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: