LineReader.hasNextLine go to a endless loop when LineReader.buffer is empty #19

Merged
e7h4n merged 1 commit from master into master 2012-02-20 17:05:18 -08:00
e7h4n commented 2012-02-20 06:17:37 -08:00 (Migrated from github.com)
   while(this.buffer.indexOf('\n') === -1) {                                
        this.getBufferAndSetCurrentPosition(this.currentPosition);           
        if(this.currentPosition === -1) return false;                        
        if(this.buffer.length === 0) return false;  // add this line                                                          
    }       
``` while(this.buffer.indexOf('\n') === -1) { this.getBufferAndSetCurrentPosition(this.currentPosition); if(this.currentPosition === -1) return false; if(this.buffer.length === 0) return false; // add this line } ```
ryanmcgrath commented 2012-02-20 17:05:37 -08:00 (Migrated from github.com)

Beautiful! Thanks for catching, will push out a point release shortly. ;)

Beautiful! Thanks for catching, will push out a point release shortly. ;)
This repository is archived. You cannot comment on pull requests.
No reviewers
No milestone
No project
No assignees
1 participant
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: code/wrench-js#19
No description provided.