CID 6925: Use snprintf. Also sizeof(size) is kind of funny.

git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@40008 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
Ryan Leavengood 2010-12-29 04:20:39 +00:00
parent 39aa9ae199
commit 43d3fdf3b1

View File

@ -298,7 +298,7 @@ ShowImageView::_UpdateStatusText()
if (fHasSelection) {
char size[50];
sprintf(size, "(%.0fx%.0f)",
snprintf(size, sizeof(size), "(%.0fx%.0f)",
fSelectionBox.Bounds().Width() + 1.0,
fSelectionBox.Bounds().Height() + 1.0);