[libdvdnav-devel] Remove unnecessary memset() calls because of calloc being used
Steve Dibb
git at videolan.org
Wed Jan 21 17:23:12 CET 2015
libdvdread | branch: master | Steve Dibb <steve.dibb at gmail.com> | Thu Jan 15 13:45:38 2015 -0700| [e381f0766f4a1cf9b0cf526b38fca445080ba94e] | committer: Jean-Baptiste Kempf
Remove unnecessary memset() calls because of calloc being used
Signed-off-by: Jean-Baptiste Kempf <jb at videolan.org>
> http://git.videolan.org/gitweb.cgi/libdvdread.git/?a=commit;h=e381f0766f4a1cf9b0cf526b38fca445080ba94e
---
src/ifo_read.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/src/ifo_read.c b/src/ifo_read.c
index e19f995..ea3c3fc 100644
--- a/src/ifo_read.c
+++ b/src/ifo_read.c
@@ -719,8 +719,6 @@ static int ifoRead_PGC_COMMAND_TBL(ifo_handle_t *ifofile,
pgc_command_tbl_t *cmd_tbl,
unsigned int offset) {
- memset(cmd_tbl, 0, sizeof(pgc_command_tbl_t));
-
if(!DVDFileSeek_(ifofile->file, offset))
return 0;
@@ -1385,7 +1383,6 @@ int ifoRead_PTL_MAIT(ifo_handle_t *ifofile) {
ifofile->ptl_mait = NULL;
return 0;
}
- memset(pf_temp, 0, info_length);
if(!(DVDReadBytes(ifofile->file, pf_temp, info_length))) {
fprintf(stderr, "libdvdread: Unable to read PTL_MAIT table at index %d.\n",i);
free(pf_temp);
@@ -1508,8 +1505,6 @@ int ifoRead_VTS_TMAPT(ifo_handle_t *ifofile) {
return 0;
}
- memset(vts_tmapt->tmap, 0, info_length); /* So ifoFree_VTS_TMAPT works. */
-
for(i = 0; i < vts_tmapt->nr_of_tmaps; i++) {
if(!DVDFileSeek_(ifofile->file, offset + vts_tmap_srp[i])) {
ifoFree_VTS_TMAPT(ifofile);
More information about the libdvdnav-devel
mailing list