fixes to readlink