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

Decorable::declareDecorationWithOwner passes wrong owner pointer to its decorations

    • Type: Icon: Bug Bug
    • Resolution: Fixed
    • Priority: Icon: Major - P3 Major - P3
    • 3.6.4
    • Affects Version/s: 3.7.2
    • Component/s: Internal Code
    • None
    • Fully Compatible
    • ALL
    • Platforms 2018-02-26, Platforms 2018-03-12

      The Decorable::declareDecorationWithOwner call instantiates a constructor function, which passes the owner pointer given to the decorations container here. However, since Decorable is a super class of the class it is enhancing, the this pointer points to where the super class starts, not where the actual decorated class is. Because of this, decorations with owner receive the wrong owner pointer here.

            Assignee:
            adam.martin@mongodb.com ADAM Martin (Inactive)
            Reporter:
            kaloian.manassiev@mongodb.com Kaloian Manassiev
            Votes:
            0 Vote for this issue
            Watchers:
            7 Start watching this issue

              Created:
              Updated:
              Resolved: