summaryrefslogtreecommitdiff
path: root/src/xine-engine/xine.c
diff options
context:
space:
mode:
authorDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2008-05-09 15:55:33 +0200
committerDiego 'Flameeyes' Pettenò <flameeyes@gmail.com>2008-05-09 15:55:33 +0200
commit1e71123be300aa08325aca68f12d54e7149bd820 (patch)
tree00f2e457fd5a860d70deb5008eb44c60da0dbbde /src/xine-engine/xine.c
parentc99cd9519a56b2d7c60fa30e9fecd02f08336671 (diff)
downloadxine-lib-1e71123be300aa08325aca68f12d54e7149bd820.tar.gz
xine-lib-1e71123be300aa08325aca68f12d54e7149bd820.tar.bz2
Remove a new bunch of xine_malloc() calls.
Also don't reset memory after it's allocated if we do that with calloc.
Diffstat (limited to 'src/xine-engine/xine.c')
-rw-r--r--src/xine-engine/xine.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/xine-engine/xine.c b/src/xine-engine/xine.c
index 92f7a2603..fd10a7401 100644
--- a/src/xine-engine/xine.c
+++ b/src/xine-engine/xine.c
@@ -1938,7 +1938,7 @@ static int _x_get_current_frame_impl (xine_stream_t *stream, int *width, int *he
uint8_t **img, int *size, int alloc_img) {
vo_frame_t *frame;
- int required_size;
+ size_t required_size;
stream->xine->port_ticket->acquire(stream->xine->port_ticket, 0);
frame = stream->video_out->get_last_frame (stream->video_out);
@@ -1993,7 +1993,7 @@ static int _x_get_current_frame_impl (xine_stream_t *stream, int *width, int *he
if (size)
*size = required_size;
/* allocate img or fail */
- if (!(*img = xine_xmalloc (required_size)))
+ if (!(*img = calloc(1, required_size)))
return 0;
} else {
/* fail if supplied buffer is to small */