Uploaded image for project: 'Core Server'
  1. Core Server
  2. SERVER-15660

PlanRanker::hasStage should protect itself against NULL pointers

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 2.7.7
    • Component/s: Querying
    • ALL
    • None
    • 0
    • None
    • None
    • None
    • None
    • None
    • None

      In the case that a null PlanStageStats* gets pushed onto the tree of children stats passed to PlanRanker::hasStage(), this method will attempt to access 'stageType' on this null pointer and seg fault.

      I imagine that in theory, null PlanStageStats pointers should never be passed to this method. However, the MockStage currently returns NULL as its stats, and that is able to propagate through to this point and crash the system.

            Assignee:
            rassi J Rassi (Inactive)
            Reporter:
            samantha.ritter@mongodb.com Samantha Ritter (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: