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

jsonString has incorrect output on undefined BSON elements.

    • Type: Icon: Bug Bug
    • Resolution: Done
    • Priority: Icon: Minor - P4 Minor - P4
    • 2.2.2, 2.3.0
    • Affects Version/s: None
    • Component/s: None
    • None
    • Minor Change
    • ALL

      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 }

      "

            Assignee:
            sverch Shaun Verch
            Reporter:
            sverch Shaun Verch
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated:
              Resolved: