summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlan Coopersmith <alan.coopersmith@oracle.com>2022-11-13 11:57:50 -0800
committerAlan Coopersmith <alan.coopersmith@oracle.com>2022-11-13 14:17:46 -0800
commitc59a8dad290489d79f82ab183dbc31b279866161 (patch)
tree1acf9b08d473c1199efb657320cb78882b21c041
parent7545e0ed63cb03e5a6065a9823710d02f560692c (diff)
set_pixels: Mark pixels parameter as const
As suggested by cppcheck: xset.c:1145:41: style: Parameter 'pixels' can be declared with const [constParameter] set_pixels(Display *dpy, unsigned long *pixels, caddr_t * colors, ^ Signed-off-by: Alan Coopersmith <alan.coopersmith@oracle.com>
-rw-r--r--xset.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/xset.c b/xset.c
index 052d705..48d9031 100644
--- a/xset.c
+++ b/xset.c
@@ -130,8 +130,8 @@ static void xkbset_led(Display *dpy, const char *led, int led_mode);
static void set_mouse(Display *dpy, int acc_num, int acc_denom, int threshold);
static void set_saver(Display *dpy, int mask, int value);
static void set_repeat(Display *dpy, int key, int auto_repeat_mode);
-static void set_pixels(Display *dpy, unsigned long *pixels, caddr_t *colors,
- int numpixels);
+static void set_pixels(Display *dpy, const unsigned long *pixels,
+ caddr_t *colors, int numpixels);
static void set_lock(Display *dpy, Bool onoff);
static const char *on_or_off(int val, int onval, const char *onstr,
int offval, const char *offstr,
@@ -1134,7 +1134,7 @@ xkbset_repeatrate(Display *dpy, int delay, int interval)
#endif
static void
-set_pixels(Display *dpy, unsigned long *pixels, caddr_t * colors,
+set_pixels(Display *dpy, const unsigned long *pixels, caddr_t * colors,
int numpixels)
{
XColor def;