Skip to content

Commit

Permalink
fixed problem with format() in tinytiffreader_test.cpp
Browse files Browse the repository at this point in the history
  • Loading branch information
jkriege2 committed Jul 20, 2020
1 parent 5ef1199 commit bf00a82
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions tests/tinytiffreader_test/tinytiffreader_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -65,12 +65,10 @@
return d;
};

std::string format(const std::string& templ, ...){
va_list ap;
template <class T>
std::string format(const std::string& templ, const T& val){
char buffer[4096];
va_start (ap, templ);
vsprintf (buffer, templ.c_str(), ap);
va_end (ap);
sprintf(buffer, templ.c_str(), val);
std::string ret(buffer);
return ret;
};
Expand Down

0 comments on commit bf00a82

Please sign in to comment.