Remove white-space from use in setThreadName

XMLWordPrintableJSON

    • Type: Improvement
    • Resolution: Fixed
    • Priority: Major - P3
    • 4.1.7
    • Affects Version/s: None
    • Component/s: None
    • Fully Compatible
    • Service Arch 2018-12-31, Service Arch 2019-01-14
    • None
    • 3
    • None
    • None
    • None
    • None
    • None
    • None

      Less robust programs may parse the proc filesystem incorrectly if there is whitespace in thread names. I propose that we debug assert that there is no whitespace in the name inside the function setThreadName.

      As of now, I've found thread names containing spaces in:

      • src/mongo/db/commands/generic.cpp
      • src/mongo/db/index_builder.cpp
      • src/mongo/db/keys_collection_manager.cpp
      • src/mongo/db/repl/oplog_applier.cpp
      • src/mongo/db/s/metadata_manager.cpp
      • src/mongo/db/s/session_catalog_migration_destination_test.cpp
      • src/mongo/db/storage/wiredtiger/wiredtiger_record_store_mongod.cpp
      • src/mongo/dbtests/deferred_writer.cpp
      • src/mongo/s/client/shard_registry.cpp

            Assignee:
            Jonathan Ma
            Reporter:
            Benjamin Caimano (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated:
              Resolved: