Fix for servers/gophermap with bad line endings

e.g: gopher://pollett.org/
This commit is contained in:
James Mills 2017-06-12 23:56:28 -07:00
parent 0f4bedb6c5
commit 435112fefe
No known key found for this signature in database
GPG Key ID: AC4C014F1440EBD6

View File

@ -385,7 +385,7 @@ func (i *Item) FetchDirectory() (Directory, error) {
scanner.Split(bufio.ScanLines)
for scanner.Scan() {
line := scanner.Text()
line := strings.Trim(scanner.Text(), "\r\n")
if len(line) == 0 {
continue