CanonicalQuery::canonicalize can leak a LiteParsedQuery

XMLWordPrintableJSON

    • Fully Compatible
    • ALL
    • Hide

      Run mongod under a leak detector, and run jstests/core/geo_s2near.js. The last line of that test, which tests a fix for SERVER-13666, issues out-of-bounds legacy coordinates to a spherical near query. This causes uassert 17444 to trigger, raising an exception and leaking the LiteParsedQuery.

      Show
      Run mongod under a leak detector, and run jstests/core/geo_s2near.js. The last line of that test, which tests a fix for SERVER-13666 , issues out-of-bounds legacy coordinates to a spherical near query. This causes uassert 17444 to trigger, raising an exception and leaking the LiteParsedQuery.
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None
    • None

      If MatchExpressionParser::parse in the 13 argument form of CanonicalQuery::canonicalize throws an exception (as can occur, for instance, at uassert 17444 in expression_geo.cpp,) then the LiteParsedQuery object returned from LiteParsedQuery::make will be leaked since it is not wrapped in an owning smart pointer.

              Assignee:
              J Rassi (Inactive)
              Reporter:
              Andrew Morrow (Inactive)
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Created:
                Updated:
                Resolved: