Mon, 06 Aug 2018 09:59:51 -0700 index: remove side-effect from failed nt_new()
Martin von Zweigbergk <martinvonz@google.com> [Mon, 06 Aug 2018 09:59:51 -0700] rev 38938
index: remove side-effect from failed nt_new() As pointed out by Yuya in the review of D4108, if realloc() fails, we would end up with an invalid nodetree instance (with nt->nodes set to NULL), which means that if it was later accessed again it would likely segfault. It's probably unlikely that much else happens in the process if it ran out memory, but we should of course do our best to handle it. This patch makes it so we don't update the nodetree in this case. Differential Revision: https://phab.mercurial-scm.org/D4154
Mon, 06 Aug 2018 22:34:37 -0700 index: remove side-effect from failed nt_init()
Martin von Zweigbergk <martinvonz@google.com> [Mon, 06 Aug 2018 22:34:37 -0700] rev 38937
index: remove side-effect from failed nt_init() As pointed out by Yuya in the review of D4108, if we run into the "overflow in nt_init" case (which I think normally happens only in repos with at least 2^26=64Mi revisions), we would leave the node tree half-initialized. Differential Revision: https://phab.mercurial-scm.org/D4153
Mon, 06 Aug 2018 22:24:34 -0700 index: use PyMem_Free() to free nodeetree instance
Martin von Zweigbergk <martinvonz@google.com> [Mon, 06 Aug 2018 22:24:34 -0700] rev 38936
index: use PyMem_Free() to free nodeetree instance As Yuya pointed out in the review of D4108, PyMem_Malloc() and PyMem_Free() should be paired. IIUC, PyMem_Malloc() may use a different allocator than malloc(), so using free() with a pointer from PyMem_Malloc() may be very wrong. Differential Revision: https://phab.mercurial-scm.org/D4152
Mon, 06 Aug 2018 22:24:00 -0700 linelog: fix infinite loop vulnerability
Jun Wu <quark@fb.com> [Mon, 06 Aug 2018 22:24:00 -0700] rev 38935
linelog: fix infinite loop vulnerability Checking `len(lines)` is not a great way of detecting infinite loops, as demonstrated in the added test. Therefore check instruction count instead. The original C implementation does not have this problem. There are a few other places where the C implementation enforces more strictly, like `a1 <= a2`, `b1 <= b2`, `rev > 0`. But they are optional. Test Plan: Add a test. The old code forces the test to time out. Differential Revision: https://phab.mercurial-scm.org/D4151
Mon, 06 Aug 2018 17:19:33 -0400 tests: fix bytes/str issues in run-tests.py caught by python3
Augie Fackler <augie@google.com> [Mon, 06 Aug 2018 17:19:33 -0400] rev 38934
tests: fix bytes/str issues in run-tests.py caught by python3 Differential Revision: https://phab.mercurial-scm.org/D4143
Mon, 06 Aug 2018 16:45:25 -0700 changegroup: assign to proper attribute
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 06 Aug 2018 16:45:25 -0700] rev 38933
changegroup: assign to proper attribute 0548f696795b accidentally assigned to self.clrevtolocalrev instead of self._clrevtolocalrev. Surprisingly, no tests failed as a result of this mistake. Curious. Differential Revision: https://phab.mercurial-scm.org/D4144
Mon, 06 Aug 2018 09:00:26 -0700 absorb: remove sf alias for command
Gregory Szorc <gregory.szorc@gmail.com> [Mon, 06 Aug 2018 09:00:26 -0700] rev 38932
absorb: remove sf alias for command I'm not even sure what it is supposed to stand for. Differential Revision: https://phab.mercurial-scm.org/D4126
Thu, 09 Aug 2018 13:04:52 +0800 hgweb: catch ParseError that's raised by revset.match() stable
Anton Shestakov <av6@dwimlabs.net> [Thu, 09 Aug 2018 13:04:52 +0800] rev 38931
hgweb: catch ParseError that's raised by revset.match() Some queries, like the demonstrated "first(::)", fail earlier than we call mfunc(), and that results in a "500 Internal Server Error". To prevent it, revset.match() also needs to be in a try-except block.
Sun, 25 Feb 2018 21:04:33 +0900 templatekw: deprecate old-style template keyword function (API)
Yuya Nishihara <yuya@tcha.org> [Sun, 25 Feb 2018 21:04:33 +0900] rev 38930
templatekw: deprecate old-style template keyword function (API) .. api:: `f(**kwargs)` style template keyword function is deprecated. Switch to new `(context, mapping)` API by declaring resource requirements. The new-style API will be the default in Mercurial 4.9. See registrar.templatekeyword for details.
Sat, 28 Jul 2018 21:19:24 +0900 hgweb: mark all lambda template keywords as new-style function
Yuya Nishihara <yuya@tcha.org> [Sat, 28 Jul 2018 21:19:24 +0900] rev 38929
hgweb: mark all lambda template keywords as new-style function This is just a temporary workaround, and will be removed in Mercurial 4.9.
(0) -30000 -10000 -3000 -1000 -300 -100 -10 +10 +100 +300 +1000 +3000 +10000 tip