Note: if you're using Ubuntu, there is a semi-official PPA that has a non-vulnerable version (2.7.3): https://launchpad.net/~git-core/+archive/ubuntu/ppa
(removed DSA link as per advice below)
https://security-tracker.debian.org/tracker/source-package/g...