From 1579d452d97dac29a5f0802daa227df1d1a78393 Mon Sep 17 00:00:00 2001 From: mmdolze Date: Wed, 29 Feb 2012 23:20:37 +0000 Subject: [PATCH] Fix a few compiler warning when compiled with -Wextra. --- server/drivers/glkproto.c | 4 ++-- server/drivers/pylcd.c | 8 ++++---- server/drivers/t6963_low.c | 2 +- server/drivers/t6963_low.h | 2 +- 4 files changed, 8 insertions(+), 8 deletions(-) diff --git a/server/drivers/glkproto.c b/server/drivers/glkproto.c index 6b02578..f6802ff 100644 --- a/server/drivers/glkproto.c +++ b/server/drivers/glkproto.c @@ -223,7 +223,7 @@ glkclose(GLKDisplay *fd) * * Send a character to the GLK */ -int INLINE +INLINE int glkput(GLKDisplay *fd, int c) { unsigned char val; @@ -266,7 +266,7 @@ glkunget(GLKDisplay *fd, int c) * * Read a character from the GLK */ -int INLINE +INLINE int glkget(GLKDisplay *fd) { unsigned char c; diff --git a/server/drivers/pylcd.c b/server/drivers/pylcd.c index 2919829..5b40023 100644 --- a/server/drivers/pylcd.c +++ b/server/drivers/pylcd.c @@ -77,7 +77,7 @@ static int read_tele(PrivateData *p, char *buffer); static int real_send_tele(PrivateData *p, char *buffer, int len); static int send_tele(PrivateData *p, char *buffer); static int send_ACK(PrivateData *p); -static unsigned long long timestamp(PrivateData *p); +static unsigned long long timestamp(void); static int initTTY(Driver *drvthis, int FD); /* local functions for pylcd.c */ @@ -239,7 +239,7 @@ send_ACK(PrivateData *p) * Returns the current time in microseconds since the Epoch. */ static unsigned long long -timestamp(PrivateData *p) +timestamp(void) { struct timeval tv; @@ -314,7 +314,7 @@ pyramid_init(Driver *drvthis) memset(p->backingstore, ' ', SCREEN_SIZE); strcpy(p->last_key_pressed, NOKEY); - p->last_key_time = timestamp(p); + p->last_key_time = timestamp(); p->timeout.tv_sec = 0; p->timeout.tv_usec = MICROTIMEOUT; @@ -1074,7 +1074,7 @@ pyramid_get_key(Driver *drvthis) if (p->last_key_pressed[0] == NOKEY[0]) return NULL; - current_time = timestamp(p); + current_time = timestamp(); if (current_time > p->last_key_time + 500000) /* New keys only every * 0.5 seconds */ p->last_key_time = current_time; diff --git a/server/drivers/t6963_low.c b/server/drivers/t6963_low.c index 9e0c95e..a1cbb54 100644 --- a/server/drivers/t6963_low.c +++ b/server/drivers/t6963_low.c @@ -145,7 +145,7 @@ t6963_low_command_word(T6963_port *p, u8 cmd, u16 word) * \param sta Bitmap of expected STA flags * \return 0 on success, -1 if ready could not be read */ -inline int +int t6963_low_dsp_ready(T6963_port *p, u8 sta) { int portcontrol = 0; diff --git a/server/drivers/t6963_low.h b/server/drivers/t6963_low.h index 648fa95..ac8d4fb 100644 --- a/server/drivers/t6963_low.h +++ b/server/drivers/t6963_low.h @@ -106,7 +106,7 @@ void t6963_low_auto_write(T6963_port *p, u8 byte); void t6963_low_command(T6963_port *p, u8 byte); void t6963_low_command_byte(T6963_port *p, u8 cmd, u8 byte); void t6963_low_command_word(T6963_port *p, u8 cmd, u16 word); -inline int t6963_low_dsp_ready(T6963_port *p, u8 sta); +int t6963_low_dsp_ready(T6963_port *p, u8 sta); inline void t6963_low_send(T6963_port *p, u8 type, u8 byte); #endif