fix vsnprintf
This commit is contained in:
parent
a4248ddef7
commit
189e89ae21
@ -2,6 +2,7 @@
|
||||
// by James Turk (james.p.turk@gmail.com)
|
||||
// Based on work by Marijn Haverbeke (http://marijn.haverbeke.nl)
|
||||
//
|
||||
// Version 0.2.2 - Released 28 February 2011 - Fixed linux compilation.
|
||||
// Version 0.2.1 - Released 2 March 2008 - Updated contact information.
|
||||
// Version 0.2.0 - Released 18 July 2005 - Added beginDraw/endDraw,
|
||||
// Changed vsprintf to vsnprintf
|
||||
@ -269,7 +270,7 @@ void GLFT_Font::drawText(float x, float y, const char *str, ...) const
|
||||
char buf[1024];
|
||||
|
||||
va_start(args,str);
|
||||
std::vsnprintf(buf, 1024, str, args); // avoid buffer overflow
|
||||
vsnprintf(buf, 1024, str, args); // avoid buffer overflow
|
||||
va_end(args);
|
||||
|
||||
glBindTexture(GL_TEXTURE_2D, texID_);
|
||||
|
@ -2,6 +2,7 @@
|
||||
// by James Turk (james.p.turk@gmail.com)
|
||||
// Based on work by Marijn Haverbeke (http://marijn.haverbeke.nl)
|
||||
//
|
||||
// Version 0.2.2 - Released 28 February 2011 - Fixed linux compilation.
|
||||
// Version 0.2.1 - Released 2 March 2008 - Updated contact information.
|
||||
// Version 0.2.0 - Released 18 July 2005 - Added beginDraw/endDraw,
|
||||
// Changed vsprintf to vsnprintf
|
||||
|
1
README
1
README
@ -2,6 +2,7 @@
|
||||
// by James Turk (james.p.turk@gmail.com)
|
||||
// Based on work by Marijn Haverbeke (http://marijn.haverbeke.nl)
|
||||
//
|
||||
// Version 0.2.2 - Released 28 February 2011 - Fixed linux compilation.
|
||||
// Version 0.2.1 - Released 2 March 2008 - Updated contact information.
|
||||
// Version 0.2.0 - Released 18 July 2005 - Added beginDraw/endDraw,
|
||||
// Changed vsprintf to vsnprintf
|
||||
|
Loading…
Reference in New Issue
Block a user