Handle potential error from os.Readlink