Uploaded image for project: 'C++ Driver'
  1. C++ Driver
  2. CXX-977

bsconcxx::to_json output error, when string value contains "

    • Type: Icon: Bug Bug
    • Resolution: Duplicate
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 3.0.1
    • Component/s: BSON
    • Labels:
      None

      json.cpp should change to replace all occurance of " (the double-quote character) !!

      void visit_value(const types::b_utf8& value) {
              std::string str = value.value.to_string().data();
              out << "\"" << replace_all(str, "\"", "\\\"") << "\"";
          }
      

            Assignee:
            backlog-cxx-driver [DO NOT USE] Backlog - CXX Driver Team
            Reporter:
            itfront itfront
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: