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

jsonString has incorrect output on undefined BSON elements.

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor - P4
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.2.2, 2.3.0
    • Component/s: None
    • Labels:
      None
    • Backwards Compatibility:
      Minor Change
    • Operating System:
      ALL

      Description

      Test case that fails:

      class SingleUndefinedMember {
      public:
      void run() {
      BSONObjBuilder b;
      b.appendUndefined( "a" );
      ASSERT_EQUALS( "

      { \"a\" : undefined }

      ", b.done().jsonString( Strict ) );
      }
      };

      jsonString outputs "

      { undefined }

      "

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: