diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/gui/guiFormSpecMenu.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/gui/guiFormSpecMenu.cpp b/src/gui/guiFormSpecMenu.cpp index 938481fa2..1ce55673d 100644 --- a/src/gui/guiFormSpecMenu.cpp +++ b/src/gui/guiFormSpecMenu.cpp @@ -1730,8 +1730,9 @@ void GUIFormSpecMenu::parseHyperText(parserData *data, const std::string &elemen { std::vector<std::string> parts = split(element, ';'); - if (parts.size() != 4 && m_formspec_version < FORMSPEC_API_VERSION) { - errorstream << "Invalid text element(" << parts.size() << "): '" << element << "'" << std::endl; + if (parts.size() != 4 && + (parts.size() < 4 || m_formspec_version <= FORMSPEC_API_VERSION)) { + errorstream << "Invalid hypertext element(" << parts.size() << "): '" << element << "'" << std::endl; return; } |