lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Dillard (JIRA)" <>
Subject [jira] Created: (LUCENE-1249) Bugs in org.apache.lucene.index.TermVectorsReader.clone()
Date Thu, 27 Mar 2008 20:03:28 GMT
Bugs in org.apache.lucene.index.TermVectorsReader.clone()

                 Key: LUCENE-1249
             Project: Lucene - Java
          Issue Type: Bug
          Components: Index
    Affects Versions: 2.3.1
            Reporter: David Dillard
            Priority: Minor
             Fix For: 2.3.2

A couple of things:

- The implementation can return null which is not allowed.  It should throw a CloneNotSupportedException
if that's the case.

- Part of the code reads:

    TermVectorsReader clone = null;
    try {
      clone = (TermVectorsReader) super.clone();
    } catch (CloneNotSupportedException e) {}

    clone.tvx = (IndexInput) tvx.clone();

If a CloneNotSupportedException is caught then "clone" will be null and the assignment to
clone.tvx will fail with a null pointer exception.

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

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message