On non-Windows platforms, a non-existent port name passed to sp_get_port_by_name() will result in SP_ERR_FAIL with ENOENT. On Windows, where port names are not file paths, there is no initial call to readpath(), and the Windows implementation of get_port_details() fails silently. As a result, it is possible to get an sp_port struct for a non-existent port and try to obtain metadata from it without errors. An error will still be returned on sp_open().