Add getCanonicalPath() function.