[PATCH:xrandr 2/2] Use __UNCONST to work around const problem.

Thomas Klausner wiz at NetBSD.org
Sun Jun 2 16:37:31 PDT 2013


On Sun, Jun 02, 2013 at 04:35:51PM -0700, Alan Coopersmith wrote:
> On 06/ 2/13 12:30 PM, Thomas Klausner wrote:
> >XXX: should probably be fixed differently.
> >---
> >  xrandr.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> >diff --git a/xrandr.c b/xrandr.c
> >index da786cb..0b285a3 100644
> >--- a/xrandr.c
> >+++ b/xrandr.c
> >@@ -1524,7 +1524,7 @@ crtc_set_transform (crtc_t *crtc, transform_t *transform)
> >      if (major > 1 || (major == 1 && minor >= 3))
> >  	XRRSetCrtcTransform (dpy, crtc->crtc.xid,
> >  			     &transform->transform,
> >-			     transform->filter,
> >+			     __UNCONST(transform->filter),
> >  			     transform->params,
> >  			     transform->nparams);
> >  }
> >
> 
> Sorry, breaks the build since __UNCONST is not defined.

Yeah, needs the bits
#ifndef __UNCONST
#define __UNCONST(x) (x)
#endif
like the other patch.

Better would be if we wouldn't need the unconst cast though :)
 Thomas


More information about the xorg-devel mailing list