Browse Source

Minor bug fix where newline was getting appended to line, rather than truncating \r

release/0.19
Jessica James 8 years ago
parent
commit
8fbb12310e
  1. 1
      .gitignore
  2. 7
      Jupiter/IRC_Client.cpp

1
.gitignore

@ -160,3 +160,4 @@ $RECYCLE.BIN/
# Visual Studio DB
*.VC.db
/.vs/config/applicationhost.config

7
Jupiter/IRC_Client.cpp

@ -1391,11 +1391,12 @@ int Jupiter::IRC::Client::think()
{
if (result.tokens[0][0] == '\n' && Jupiter::IRC::Client::data_->last_line[Jupiter::IRC::Client::data_->last_line.size() - 1] == '\r')
{
Jupiter::IRC::Client::data_->last_line += '\n';
Jupiter::IRC::Client::process_line(Jupiter::IRC::Client::data_->last_line);
Jupiter::IRC::Client::data_->last_line.truncate(1); // Remove \r
Jupiter::IRC::Client::process_line(Jupiter::IRC::Client::data_->last_line);
Jupiter::IRC::Client::data_->last_line.erase();
result.tokens[0].shiftRight(1);
result.tokens[0].shiftRight(1); // Remove \n
}
}

Loading…
Cancel
Save