summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--tools/bmp2rb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/tools/bmp2rb.c b/tools/bmp2rb.c
index 48068b1..f7b92d0 100644
--- a/tools/bmp2rb.c
+++ b/tools/bmp2rb.c
@@ -320,7 +320,7 @@ int transform_bitmap(const struct RGBQUAD *src, long width, long height,
return 1;
}
- *dest = (unsigned short *)malloc(dst_w * dst_h);
+ *dest = (unsigned short *)malloc(dst_w * dst_h * sizeof(short));
if (*dest == NULL)
{
debugf("error - Out of memory.\n");