diff options
author | MadCamel <madcamel@gmail.com> | 2009-02-11 19:27:13 -0500 |
---|---|---|
committer | Jared Adams <jaxad0127@gmail.com> | 2009-02-11 18:16:21 +0000 |
commit | 37f0aeb23e60d3960bd0f8164d60fec951ebcd8c (patch) | |
tree | a91f65c9d6e12a9e8aa9edc1d33930f98684dca3 | |
parent | 5e01985ee82007307c96f900057679485b977196 (diff) | |
download | mana-37f0aeb23e60d3960bd0f8164d60fec951ebcd8c.tar.gz mana-37f0aeb23e60d3960bd0f8164d60fec951ebcd8c.tar.bz2 mana-37f0aeb23e60d3960bd0f8164d60fec951ebcd8c.tar.xz mana-37f0aeb23e60d3960bd0f8164d60fec951ebcd8c.zip |
Fixed crash when sending a blank item link
-rw-r--r-- | src/gui/chat.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/gui/chat.cpp b/src/gui/chat.cpp index 2845691a..38a83ce0 100644 --- a/src/gui/chat.cpp +++ b/src/gui/chat.cpp @@ -367,7 +367,7 @@ void ChatWindow::chatSend(const std::string &nick, std::string msg) while (start != std::string::npos && msg[start+1] != '@') { std::string::size_type end = msg.find(']', start); - if (end != std::string::npos) + if (start+1 != end && end != std::string::npos) { // Catch multiple embeds and ignore them so it doesn't crash the client. while ((msg.find('[', start + 1) != std::string::npos) && |