mtr: import a patch from upstream to fix segfault

There is a buffer overflow problem in mtr which is fixed upstream, and
can be reproduced with:

❯ mtr -z -4 -c 5 -w example.com
Start: 2023-09-12T09:38:31+0000
*** buffer overflow detected ***: terminated
[1] 293109 abort (core dumped) mtr -z -4 -c 5 -w example.com

+6
+6
pkgs/tools/networking/mtr/default.nix
··· 1 { stdenv 2 , lib 3 , fetchFromGitHub 4 , autoreconfHook 5 , pkg-config 6 , libcap ··· 20 rev = "v${version}"; 21 sha256 = "sha256-f5bL3IdXibIc1xXCuZHwcEV5vhypRE2mLsS3A8HW2QM="; 22 }; 23 24 # we need this before autoreconfHook does its thing 25 postPatch = ''
··· 1 { stdenv 2 , lib 3 , fetchFromGitHub 4 + , fetchpatch 5 , autoreconfHook 6 , pkg-config 7 , libcap ··· 21 rev = "v${version}"; 22 sha256 = "sha256-f5bL3IdXibIc1xXCuZHwcEV5vhypRE2mLsS3A8HW2QM="; 23 }; 24 + 25 + patches = [ (fetchpatch { # https://github.com/traviscross/mtr/pull/468 26 + url = "https://github.com/traviscross/mtr/commit/5908af4c19188cb17b62f23368b6ef462831a0cb.patch"; 27 + hash = "sha256-rTydtU8+Wc4nGEKh1GOkhcpgME4hwsACy82gKPaIe64="; 28 + }) ]; 29 30 # we need this before autoreconfHook does its thing 31 postPatch = ''