Skip to content

Commit

Permalink
Fix Calculator::message()
Browse files Browse the repository at this point in the history
  • Loading branch information
Hanna K committed Feb 25, 2017
1 parent 486509f commit 6f73c0a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions libqalculate/Calculator.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1471,13 +1471,13 @@ void Calculator::error(bool critical, const char *TEMPLATE, ...) {
void Calculator::message(MessageType mtype, int message_category, const char *TEMPLATE, ...) {
va_list ap;
va_start(ap, TEMPLATE);
error(mtype, message_category, TEMPLATE, ap);
message(mtype, message_category, TEMPLATE, ap);
va_end(ap);
}
void Calculator::message(MessageType mtype, const char *TEMPLATE, ...) {
va_list ap;
va_start(ap, TEMPLATE);
error(mtype, MESSAGE_CATEGORY_NONE, TEMPLATE, ap);
message(mtype, MESSAGE_CATEGORY_NONE, TEMPLATE, ap);
va_end(ap);
}
void Calculator::message(MessageType mtype, int message_category, const char *TEMPLATE, va_list ap) {
Expand Down
2 changes: 1 addition & 1 deletion libqalculate/DataSet.cc
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ bool DataSet::loadObjects(const char *file_name, bool is_user_defs) {
xmlFreeDoc(doc);
b_loaded = true;
if(!scopyright.empty()) {
CALCULATOR->message(MESSAGE_INFORMATION, "%s", scopyright.c_str(), NULL);
CALCULATOR->message(MESSAGE_INFORMATION, scopyright.c_str(), NULL);
}
return true;
}
Expand Down

0 comments on commit 6f73c0a

Please sign in to comment.