generateFingerprint
Build an 8-character client fingerprint string in libtorrent's Azureus style, porting generate_fingerprint(std::string name, int major, int minor, int revision, int tag).
Return
the "-XXmmtt-" style 8-character prefix.
Parameters
the two-character client identifier (e.g. "KT", "LT"). libtorrent requires exactly two characters; if fewer than two are given it substitutes "--" (matching if (name.size() < 2) name = "--"). More than two characters is a precondition violation upstream. We require exactly two (after the short-string fallback) to avoid silently truncating.
major version, encoded by versionToChar into slot 3.
minor version, encoded into slot 4. Defaults to 0.
revision version (libtorrent's revision), slot 5. Defaults to 0.
build/tag version, slot 6. Defaults to 0.