Skip to content

Commit

Permalink
Fix bug where an empty parameter is generated when input to a tokenst…
Browse files Browse the repository at this point in the history
…ream ends in a colon
  • Loading branch information
Jackmcbarn committed Jan 22, 2011
1 parent aceb2c4 commit a18c7c4
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/hashcomp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -199,7 +199,7 @@ bool irc::tokenstream::GetToken(std::string &token)
/* If we find a space, or end of string, this is the end of a token.
*/
last_starting_position = n+1;
last_pushed = true;
last_pushed = *n == ' ';

std::string strip(lsp, n+1 == tokens.end() ? n+1 : n++);
while ((strip.length()) && (strip.find_last_of(' ') == strip.length() - 1))
Expand Down

0 comments on commit a18c7c4

Please sign in to comment.