[MPlayer-cvslog] r31805 - trunk/libvo/vo_corevideo.m

reimar subversion at mplayerhq.hu
Sun Jul 25 13:19:41 CEST 2010


Author: reimar
Date: Sun Jul 25 13:19:41 2010
New Revision: 31805

Log:
Declare variables with proper types to avoid dangerous pointer casts.

Modified:
   trunk/libvo/vo_corevideo.m

Modified: trunk/libvo/vo_corevideo.m
==============================================================================
--- trunk/libvo/vo_corevideo.m	Sun Jul 25 13:18:04 2010	(r31804)
+++ trunk/libvo/vo_corevideo.m	Sun Jul 25 13:19:41 2010	(r31805)
@@ -685,8 +685,7 @@ static int control(uint32_t request, voi
 */
 - (void)reshape
 {
-	uint32_t d_width;
-	uint32_t d_height;
+	int d_width, d_height;
 
 	NSRect frame = [self frame];
 	vo_dwidth  = frame.size.width;
@@ -702,7 +701,7 @@ static int control(uint32_t request, voi
 	//set texture frame
 	if(vo_keepaspect)
 	{
-		aspect( (int *)&d_width, (int *)&d_height, A_WINZOOM);
+		aspect(&d_width, &d_height, A_WINZOOM);
 
 		textureFrame = NSMakeRect((vo_dwidth - d_width) / 2, (vo_dheight - d_height) / 2, d_width, d_height);
 	}


More information about the MPlayer-cvslog mailing list