diff options
Diffstat (limited to 'src/mesa/main/debug.c')
-rw-r--r-- | src/mesa/main/debug.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/main/debug.c b/src/mesa/main/debug.c index 9bcfc1008a..526145aecc 100644 --- a/src/mesa/main/debug.c +++ b/src/mesa/main/debug.c @@ -315,7 +315,7 @@ write_texture_image(struct gl_texture_object *texObj, buffer, texObj, img); /* make filename */ - sprintf(s, "/tmp/tex%u.l%u.f%u.ppm", texObj->Name, level, face); + _mesa_snprintf(s, sizeof(s), "/tmp/tex%u.l%u.f%u.ppm", texObj->Name, level, face); printf(" Writing image level %u to %s\n", level, s); write_ppm(s, buffer, img->Width, img->Height, 4, 0, 1, 2, GL_FALSE); @@ -357,7 +357,7 @@ write_renderbuffer_image(const struct gl_renderbuffer *rb) format, type, &ctx->DefaultPacking, buffer); /* make filename */ - sprintf(s, "/tmp/renderbuffer%u.ppm", rb->Name); + _mesa_snprintf(s, sizeof(s), "/tmp/renderbuffer%u.ppm", rb->Name); printf(" Writing renderbuffer image to %s\n", s); write_ppm(s, buffer, rb->Width, rb->Height, 4, 0, 1, 2, GL_TRUE); |