labath accepted this revision. labath added a comment. This revision is now accepted and ready to land.
Agreed we generally don't want to have embedded nuls in the command output, but I don't think we have to go to such great lengths to enforce it. > The latter doesn't trigger this bug because it writes directly to the output > stream and therefore bypasses PrintCommandOutput but that's just an > implementation detail. I guess this would be triggered by `sb_command_return_object.PutOutput("\0")` ================ Comment at: lldb/source/Interpreter/CommandInterpreter.cpp:2988-2994 size_t chunk_size = 0; for (; chunk_size < size; ++chunk_size) { - lldbassert(data[chunk_size] != '\0'); if (data[chunk_size] == '\n') { ++chunk_size; break; } } ---------------- I guess this could now be something like `std::tie(line, str) = str.split('\n');` CHANGES SINCE LAST ACTION https://reviews.llvm.org/D122025/new/ https://reviews.llvm.org/D122025 _______________________________________________ lldb-commits mailing list lldb-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits