Fix issue 10338
Merge pull request #2166 from mxfm/fixlink

[trivial] Minor issue in link.c