diff options
Diffstat (limited to 'src/libxinevdec/rgb.c')
-rw-r--r-- | src/libxinevdec/rgb.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/libxinevdec/rgb.c b/src/libxinevdec/rgb.c index 0e7be4c18..fc206a0ce 100644 --- a/src/libxinevdec/rgb.c +++ b/src/libxinevdec/rgb.c @@ -31,6 +31,10 @@ * indicated by a negative height parameter. */ +#ifdef HAVE_CONFIG_H +#include "config.h" +#endif + #include <stdio.h> #include <stdlib.h> #include <string.h> @@ -145,7 +149,7 @@ static void rgb_decode_data (video_decoder_t *this_gen, /* minimal buffer size */ this->bufsize = this->width * this->height * this->bytes_per_pixel; - this->buf = xine_xmalloc(this->bufsize); + this->buf = calloc(1, this->bufsize); this->size = 0; init_yuv_planes(&this->yuv_planes, this->width, this->height); @@ -398,7 +402,7 @@ static video_decoder_t *open_plugin (video_decoder_class_t *class_gen, xine_stre rgb_decoder_t *this ; - this = (rgb_decoder_t *) xine_xmalloc (sizeof (rgb_decoder_t)); + this = (rgb_decoder_t *) calloc(1, sizeof(rgb_decoder_t)); this->video_decoder.decode_data = rgb_decode_data; this->video_decoder.flush = rgb_flush; @@ -432,7 +436,7 @@ static void *init_plugin (xine_t *xine, void *data) { rgb_class_t *this; - this = (rgb_class_t *) xine_xmalloc (sizeof (rgb_class_t)); + this = (rgb_class_t *) calloc(1, sizeof(rgb_class_t)); this->decoder_class.open_plugin = open_plugin; this->decoder_class.get_identifier = get_identifier; |