comparison libdvdread/dvd_reader.c @ 372:7cf80b1cba5a src

fixed incorrect type cast; patch by Erik Hovland org
author nicodvb
date Thu, 05 Jun 2008 10:19:26 +0000
parents 1274107d0eac
children
comparison
equal deleted inserted replaced
371:587353009f65 372:7cf80b1cba5a
1134 dvd_file_t *dvd_file = DVDOpenFile( dvd, title, DVD_READ_INFO_FILE ); 1134 dvd_file_t *dvd_file = DVDOpenFile( dvd, title, DVD_READ_INFO_FILE );
1135 if( dvd_file != NULL ) { 1135 if( dvd_file != NULL ) {
1136 ssize_t bytes_read; 1136 ssize_t bytes_read;
1137 size_t file_size = dvd_file->filesize * DVD_VIDEO_LB_LEN; 1137 size_t file_size = dvd_file->filesize * DVD_VIDEO_LB_LEN;
1138 char *buffer_base = malloc( file_size + 2048 ); 1138 char *buffer_base = malloc( file_size + 2048 );
1139 char *buffer = (unsigned char *)(((uintptr_t)buffer_base & ~((uintptr_t)2047)) + 2048); 1139 char *buffer = (char *)(((uintptr_t)buffer_base & ~((uintptr_t)2047)) + 2048);
1140 1140
1141 if( buffer_base == NULL ) { 1141 if( buffer_base == NULL ) {
1142 DVDCloseFile( dvd_file ); 1142 DVDCloseFile( dvd_file );
1143 fprintf( stderr, "libdvdread: DVDDiscId, failed to " 1143 fprintf( stderr, "libdvdread: DVDDiscId, failed to "
1144 "allocate memory for file read!\n" ); 1144 "allocate memory for file read!\n" );