Skip to content
This repository has been archived by the owner on Feb 26, 2019. It is now read-only.

Handle lines longer than 64k #231

Merged
merged 5 commits into from
Jun 17, 2015
Merged

Handle lines longer than 64k #231

merged 5 commits into from
Jun 17, 2015

Conversation

freeformz
Copy link

Handle lines longer than 64k.

/cc @kr #228 #160 #179

Edward Muller added 3 commits June 16, 2015 15:32
@freeformz freeformz changed the title 64k lines Handle lines longer than 64k Jun 17, 2015
if err != nil {
return err
if err == io.EOF {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It would be pretty cool to pull this out in front of the surrounding if stmt:

l, err := b.ReadBytes('\n')
eof := err == io.EOF
if err != nil && err != io.EOF {
  return err
}

This is a bit cleaner.
@freeformz
Copy link
Author

@kr Done. If it LGTY, then I'll merge it.

}
}

// If we're at the EOF exit
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The comments in this function don't really add anything meaningful. I would delete them.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed.

freeformz pushed a commit that referenced this pull request Jun 17, 2015
Handle lines longer than 64k
@freeformz freeformz merged commit 5fb0c8e into master Jun 17, 2015
@freeformz freeformz deleted the 64k_lines branch June 17, 2015 23:06
@kr
Copy link
Member

kr commented Jun 17, 2015

+1 LGTM

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants