[Intel-gfx] [PATCH] Fix compiler warning in i830_copy_video_data() if XvMC is disabled

Tobias Doerffel tobias.doerffel at gmail.com
Wed Dec 9 09:57:20 CET 2009


The variable "intel" is unused when building i830_video.c without XvMC
support which results in a compiler warning:

  i830_video.c: In function 'i830_copy_video_data':
  i830_video.c:1443: warning: unused variable `intel'

Trivial fix via #ifdef.
---
 src/i830_video.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/i830_video.c b/src/i830_video.c
index b0403d4..2343316 100644
--- a/src/i830_video.c
+++ b/src/i830_video.c
@@ -1440,7 +1440,9 @@ i830_copy_video_data(ScrnInfoPtr scrn, intel_adaptor_private *adaptor_priv,
 		     INT32 x1, INT32 y1, INT32 x2, INT32 y2,
 		     int id, unsigned char *buf)
 {
+#ifdef INTEL_XVMC
 	intel_screen_private *intel = intel_get_screen_private(scrn);
+#endif
 	int srcPitch = 0, srcPitch2 = 0;
 	int top, left, npixels, nlines, size;
 
-- 
1.6.5




More information about the Intel-gfx mailing list