From b63759b175cf9ddd9735ca0d2f803fe62f69c3c3 Mon Sep 17 00:00:00 2001 From: diego Date: Fri, 26 Feb 2010 15:01:37 +0000 Subject: Do not cast the results of malloc/calloc/realloc. These functions return void*, which is compatible with any pointer, so there is no need for casts. git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@30744 b3059339-0415-0410-9bf9-f77b7e298cf2 --- subreader.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'subreader.c') diff --git a/subreader.c b/subreader.c index ddbd2839df..bbabda8511 100644 --- a/subreader.c +++ b/subreader.c @@ -1655,7 +1655,7 @@ if ((suboverlap_enabled == 2) || if (higher_line >= SUB_MAX_TEXT) { // the 'block' has too much lines, so we don't overlap the // subtitles - second = (subtitle *) realloc(second, (sub_num + sub_to_add + 1) * sizeof(subtitle)); + second = realloc(second, (sub_num + sub_to_add + 1) * sizeof(subtitle)); for (j = 0; j <= sub_to_add; ++j) { int ls; memset(&second[sub_num + j], '\0', sizeof(subtitle)); @@ -1675,7 +1675,7 @@ if ((suboverlap_enabled == 2) || // we read the placeholder structure and create the new // subs. - second = (subtitle *) realloc(second, (sub_num + 1) * sizeof(subtitle)); + second = realloc(second, (sub_num + 1) * sizeof(subtitle)); memset(&second[sub_num], '\0', sizeof(subtitle)); second[sub_num].start = local_start; second[sub_num].end = local_end; -- cgit v1.2.3