Use getcwd() instead of get_current_dir_name().