From 423e8e13d7a22a9ee64cb152dadcdc91f8093c7b Mon Sep 17 00:00:00 2001 From: Matthew Fernandez Date: Thu, 5 May 2022 17:42:13 -0700 Subject: [PATCH] smyrna: squash -Wunused-parameter warnings for GLUT callbacks These functions need to conform to a particular type signature. --- cmd/smyrna/glutrender.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/cmd/smyrna/glutrender.c b/cmd/smyrna/glutrender.c index 5c758ad0c..941f3babc 100644 --- a/cmd/smyrna/glutrender.c +++ b/cmd/smyrna/glutrender.c @@ -151,6 +151,9 @@ static void cb_drag(int X, int Y) static void cb_keyboard(unsigned char key, int x, int y) { + (void)x; + (void)y; + if (key==27) /*ESC*/ graphviz_exit(1); if(key=='3') @@ -172,12 +175,17 @@ static void cb_keyboard(unsigned char key, int x, int y) static void cb_keyboard_up(unsigned char key, int x, int y) { (void)key; + (void)x; + (void)y; appmouse_key_release(view); } static void cb_special_key(int key, int x, int y) { + (void)x; + (void)y; + if(key==GLUT_KEY_F1) { printf("Currently help is not available\n"); @@ -188,6 +196,9 @@ static void cb_special_key(int key, int x, int y) static void cb_special_key_up(int key, int x, int y) { + (void)x; + (void)y; + if(key==GLUT_KEY_F1) { printf("Currently help is not available\n"); -- 2.40.0