Uploaded image for project: 'Thrift'
  1. Thrift
  2. THRIFT-4368

Guaranteed NPE in TBaseAsyncProcessor.java

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 0.10.0
    • 0.13.0
    • Java - Library
    • None

    Description

      While creating a pull request for another ticket, the null-analyzer of Eclipse found a guaranteed NullPointerException in org.apache.thrift.TBaseAsyncProcessor<I>.

      In the method process(AsyncFrameBuffer) we see this code fragment:

          AsyncProcessFunction fn = processMap.get(msg.name);
              if (fn == null) {
                  TProtocolUtil.skip(in, TType.STRUCT);
                  in.readMessageEnd();
                  if (!fn.isOneway()) {
      

      The variable fn can only be null in the last line.

      Attachments

        Issue Links

          Activity

            People

              jking3 James E. King III
              ChristianCiach Christian Ciach
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0h
                  0h
                  Logged:
                  Time Spent - 20m
                  20m