Uploaded image for project: 'CAL10N'
  1. CAL10N
  2. CAL-22

Parser fails to load properties file if value contains space only

    XMLWordPrintable

Details

    • Icon: Bug Bug
    • Resolution: Unresolved
    • Icon: Major Major
    • None
    • None
    • None

    Description

      Cal10n fails if a property looks like this:
      "KEY = " or more spaces after the equals sign. The exception is:
      Exception in thread "main" java.lang.IllegalStateException: Unexpected token Token(EOL)
      at ch.qos.cal10n.util.Parser.E(Parser.java:76)
      at ch.qos.cal10n.util.Parser.parseAndPopulate(Parser.java:60)
      at ch.qos.cal10n.util.CAL10NResourceBundle.read(CAL10NResourceBundle.java:57)
      at ch.qos.cal10n.util.CAL10NResourceBundle.<init>(CAL10NResourceBundle.java:50)
      at ch.qos.cal10n.util.CAL10NResourceBundleFinder.makePropertyResourceBundle(CAL10NResourceBundleFinder.java:83)
      at ch.qos.cal10n.util.CAL10NResourceBundleFinder.getBundle(CAL10NResourceBundleFinder.java:51)
      at ch.qos.cal10n.MessageConveyor.lookup(MessageConveyor.java:111)
      at ch.qos.cal10n.MessageConveyor.getMessage(MessageConveyor.java:77)

      Regular java.util.Properties does not fail.

      Attachments

        Activity

          People

            ceki Ceki Gülcü
            michael-o Michael Osipov
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: