file-readline: How to check error reason