diff options
author | Alan Coopersmith <alan.coopersmith@oracle.com> | 2013-05-17 21:47:39 -0700 |
---|---|---|
committer | Alan Coopersmith <alan.coopersmith@oracle.com> | 2013-05-17 21:47:39 -0700 |
commit | a9f3465dc1d5fcd0c79d5b12bc09fe48e62d7823 (patch) | |
tree | dbfb6ebc9df62c808a82aa2b6bae8f0998ca560a | |
parent | a5ae058401d073d1af80214133fbe7f9a9cecbdb (diff) |
Rename state argument to SetButton to not shadow global state variable
xcutsel.c:196: warning: declaration of 'state' shadows a global declaration
xcutsel.c:84: warning: shadowed declaration is here
Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r-- | xcutsel.c | 10 |
1 files changed, 5 insertions, 5 deletions
@@ -193,18 +193,18 @@ ConvertSelection(Widget w, Atom *selection, Atom *target, static void -SetButton(ButtonState *state, Boolean on) +SetButton(ButtonState *statep, Boolean on) { - if (state->is_on != on) { + if (statep->is_on != on) { Arg args[2]; Pixel fg, bg; XtSetArg( args[0], XtNforeground, &fg ); XtSetArg( args[1], XtNbackground, &bg ); - XtGetValues( state->button, args, TWO ); + XtGetValues( statep->button, args, TWO ); args[0].value = (XtArgVal)bg; args[1].value = (XtArgVal)fg; - XtSetValues( state->button, args, TWO ); - state->is_on = on; + XtSetValues( statep->button, args, TWO ); + statep->is_on = on; } } |