aboutsummaryrefslogtreecommitdiff
path: root/src/guiscalingfilter.cpp
diff options
context:
space:
mode:
authornOOb3167 <nOOb3167@gmail.com>2018-07-22 21:56:06 +0200
committerSmallJoker <SmallJoker@users.noreply.github.com>2018-07-22 21:56:06 +0200
commit9537cfd3f8264700619f58d15741829489e1099e (patch)
tree36412677aba19e1a2037db7fad2f934a2daa5046 /src/guiscalingfilter.cpp
parent9855651c06f84f29780cf6b25a392ac841b4630c (diff)
downloadminetest-9537cfd3f8264700619f58d15741829489e1099e.tar.gz
minetest-9537cfd3f8264700619f58d15741829489e1099e.tar.bz2
minetest-9537cfd3f8264700619f58d15741829489e1099e.zip
Add a MSVC / Windows compatible snprintf function (#7353)
Use sizeof where applicable for mt_snprintf
Diffstat (limited to 'src/guiscalingfilter.cpp')
-rw-r--r--src/guiscalingfilter.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/guiscalingfilter.cpp b/src/guiscalingfilter.cpp
index dc6219b60..3b4377da5 100644
--- a/src/guiscalingfilter.cpp
+++ b/src/guiscalingfilter.cpp
@@ -18,6 +18,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
#include "guiscalingfilter.h"
#include "imagefilters.h"
+#include "porting.h"
#include "settings.h"
#include "util/numeric.h"
#include <cstdio>
@@ -78,7 +79,7 @@ video::ITexture *guiScalingResizeCached(video::IVideoDriver *driver,
// Calculate scaled texture name.
char rectstr[200];
- snprintf(rectstr, sizeof(rectstr), "%d:%d:%d:%d:%d:%d",
+ porting::mt_snprintf(rectstr, sizeof(rectstr), "%d:%d:%d:%d:%d:%d",
srcrect.UpperLeftCorner.X,
srcrect.UpperLeftCorner.Y,
srcrect.getWidth(),