diff options
author | Eric Anholt <eric@anholt.net> | 2013-08-17 14:50:37 +0200 |
---|---|---|
committer | Eric Anholt <eric@anholt.net> | 2013-08-21 09:10:49 -0700 |
commit | e01a3f65d3e6d92f92ef2992b338cc9625bde082 (patch) | |
tree | d4e23c380534b2f917ba8889d8f6fcc3a7d7cafd | |
parent | f1cefe020bd21c07dfcc9f204e79939499abbd35 (diff) |
ephyr: Fix warning about XID vs unsigned long * by changing function argsephyr-warnings
There's no reason to pass the data back out to the caller, since the
caller was dropping it on the floor. The original data is a CARD32,
so no need to mess with weird unsigned longs.
Signed-off-by: Eric Anholt <eric@anholt.net>
Reviewed-by: Julien Cristau <jcristau@debian.org>
-rw-r--r-- | hw/kdrive/ephyr/ephyrdri.c | 5 | ||||
-rw-r--r-- | hw/kdrive/ephyr/ephyrdri.h | 2 | ||||
-rw-r--r-- | hw/kdrive/ephyr/ephyrdriext.c | 4 |
3 files changed, 5 insertions, 6 deletions
diff --git a/hw/kdrive/ephyr/ephyrdri.c b/hw/kdrive/ephyr/ephyrdri.c index 50554364c..3a4a06301 100644 --- a/hw/kdrive/ephyr/ephyrdri.c +++ b/hw/kdrive/ephyr/ephyrdri.c @@ -137,18 +137,19 @@ ephyrDRIGetClientDriverName(int a_screen, Bool ephyrDRICreateContext(int a_screen, int a_visual_id, - XID *a_returned_ctxt_id, drm_context_t * a_hw_ctxt) + CARD32 ctxt_id, drm_context_t * a_hw_ctxt) { Display *dpy = hostx_get_display(); Bool is_ok = FALSE; Visual v; + XID returned_ctxt_id = ctxt_id; EPHYR_LOG("enter. screen:%d, visual:%d\n", a_screen, a_visual_id); memset(&v, 0, sizeof(v)); v.visualid = a_visual_id; is_ok = XF86DRICreateContext(dpy, DefaultScreen(dpy), - &v, a_returned_ctxt_id, a_hw_ctxt); + &v, &returned_ctxt_id, a_hw_ctxt); EPHYR_LOG("leave:%d\n", is_ok); return is_ok; } diff --git a/hw/kdrive/ephyr/ephyrdri.h b/hw/kdrive/ephyr/ephyrdri.h index d28910f29..8f2d3026e 100644 --- a/hw/kdrive/ephyr/ephyrdri.h +++ b/hw/kdrive/ephyr/ephyrdri.h @@ -43,7 +43,7 @@ Bool ephyrDRIGetClientDriverName(int a_screen, char **a_client_driver_name); Bool ephyrDRICreateContext(int a_screen, int a_visual_id, - XID *a_returned_ctx_id, drm_context_t * a_hw_ctx); + CARD32 ctx_id, drm_context_t * a_hw_ctx); Bool ephyrDRIDestroyContext(int a_screen, int a_context_id); Bool ephyrDRICreateDrawable(int a_screen, int a_drawable, drm_drawable_t * a_hw_drawable); diff --git a/hw/kdrive/ephyr/ephyrdriext.c b/hw/kdrive/ephyr/ephyrdriext.c index 4db40e34e..617ffb158 100644 --- a/hw/kdrive/ephyr/ephyrdriext.c +++ b/hw/kdrive/ephyr/ephyrdriext.c @@ -716,7 +716,6 @@ ProcXF86DRICreateContext(register ClientPtr client) ScreenPtr pScreen; VisualPtr visual; int i = 0; - unsigned long context_id = 0; REQUEST(xXF86DRICreateContextReq); REQUEST_SIZE_MATCH(xXF86DRICreateContextReq); @@ -739,10 +738,9 @@ ProcXF86DRICreateContext(register ClientPtr client) return BadValue; } - context_id = stuff->context; if (!ephyrDRICreateContext(stuff->screen, stuff->visual, - &context_id, + stuff->context, (drm_context_t *) &rep.hHWContext)) { return BadValue; } |