When the $uri variable is set from accessing the cgi->param('uri') value retrieved from the URL in tracklinks.pl if the uri to be redirected to contains a ampersand the ampersand and any content after it is ignored and not assigned to the $uri value. This is because when values are passed via the URL the ampersand is the delimiter between the variables and so any values after the ampersand are not considered to belong to uri. This results in a 404 error being displayed when track clicks is enabled and the URL in the biblio's 856$u contains an ampersand.
Turned out to be an issue with the URL encoding in the XSLT