zeroconf: fix an issue concatenating bytes and str
`bytes(length)` doesn't do what we want, so use `str`.
There appear to be a ton more issues in this extension, including:
- globals()[b'_GLOBAL_DONE'] using bytes as the key
- `__author__` and similar using bytes
- `BadDomainName` is feeding bytes to the Exception constructor
- DNSRecord.toString() has the wrong signature (should be str, not bytes)
Differential Revision: https://phab.mercurial-scm.org/D11303
revlog: fix more type confusion in index_replace_sidedata_info (
issue6580)
We were telling python that "rev" was a Py_ssize_t (via the "n" format),
but it was actually an int.
Differential Revision: https://phab.mercurial-scm.org/D11335
revlog: fix type confusion with sidedata_comp_len (
issue6580)
The format string uses "i" (int) for sidedata_comp_len, so we shouldn't
be passing a pointer to Py_ssize_t to PyArg_ParseTuple. On 64-bit
big-endian, this would result in python only writing to the upper 32
bits, and things go downhill from there.
Differential Revision: https://phab.mercurial-scm.org/D11334
dirstate: directly call the dirstatemap in `set_untracked`
This function is only called in two places: the deprecated "remove" method and
in the new `set_untracked` method.
So we simply inline the appropriate content in `set_untracked`, paving the way
to dropping the deprecated code and its associated function.
Differential Revision: https://phab.mercurial-scm.org/D11313