# HG changeset patch # User Mikael Berthe # Date 1223663355 -7200 # Node ID 3df441efb7c25224062596953f768b0da16bccf8 # Parent 31422cb7335653a68b7d46be892b671fb6c7e323 Fix gcc warnings related to inline/static uses diff -r 31422cb73356 -r 3df441efb7c2 mcabber/libjabber/pool.c --- a/mcabber/libjabber/pool.c Fri Oct 10 19:31:41 2008 +0200 +++ b/mcabber/libjabber/pool.c Fri Oct 10 20:29:15 2008 +0200 @@ -61,6 +61,8 @@ int pool__ltotal = 0; xht pool__disturbed = NULL; +inline void *_retried__malloc(size_t size); + /** * create a new memory allocation and increment the pool__total counter * @@ -101,7 +103,7 @@ * @param size how many bytes of memory we allocate * @return pointer to the allocated memory */ -inline void *_retried__malloc(size_t size) { +void *_retried__malloc(size_t size) { void *allocated_memory; int malloc_tries = 0; diff -r 31422cb73356 -r 3df441efb7c2 mcabber/src/jab_iq.c --- a/mcabber/src/jab_iq.c Fri Oct 10 19:31:41 2008 +0200 +++ b/mcabber/src/jab_iq.c Fri Oct 10 20:29:15 2008 +0200 @@ -69,6 +69,8 @@ typedef void (*adhoc_command_callback)(jconn, char*, const char*, xmlnode); +inline double seconds_since_last_use(void); + struct adhoc_command { char *name; char *description; @@ -1468,7 +1470,7 @@ xmlnode_free(x); } -inline double seconds_since_last_use(void) +double seconds_since_last_use(void) { return difftime(time(NULL), iqlast); } diff -r 31422cb73356 -r 3df441efb7c2 mcabber/src/jabglue.c --- a/mcabber/src/jabglue.c Fri Oct 10 19:31:41 2008 +0200 +++ b/mcabber/src/jabglue.c Fri Oct 10 20:29:15 2008 +0200 @@ -72,6 +72,8 @@ static int evscallback_invitation(eviqs *evp, guint evcontext); +inline void update_last_use(void); + static void logger(jconn j, int io, const char *buf) { @@ -354,7 +356,7 @@ return mystatusmsg; } -inline void update_last_use(void) +void update_last_use(void) { iqlast = time(NULL); } diff -r 31422cb73356 -r 3df441efb7c2 mcabber/src/screen.c --- a/mcabber/src/screen.c Fri Oct 10 19:31:41 2008 +0200 +++ b/mcabber/src/screen.c Fri Oct 10 20:29:15 2008 +0200 @@ -155,6 +155,9 @@ unsigned int prefix_flags, int force_show, unsigned mucnicklen); +inline void scr_WriteMessage(const char *bjid, const char *text, + time_t timestamp, guint prefix_flags, + unsigned mucnicklen); inline void scr_UpdateBuddyWindow(void); inline void scr_set_chatmode(int enable); @@ -2028,9 +2031,9 @@ } #endif -inline void scr_WriteMessage(const char *bjid, const char *text, - time_t timestamp, guint prefix_flags, - unsigned mucnicklen) +void scr_WriteMessage(const char *bjid, const char *text, + time_t timestamp, guint prefix_flags, + unsigned mucnicklen) { char *xtext; @@ -2153,7 +2156,7 @@ } #if defined JEP0022 || defined JEP0085 -inline long int scr_GetChatStatesTimeout(time_t now) +long int scr_GetChatStatesTimeout(time_t now) { // Check if we're currently composing... if (chatstate != 1 || !chatstate_timestamp) @@ -2932,7 +2935,7 @@ // scr_cmdhisto_addline() // Add a line to the inputLine history -inline void scr_cmdhisto_addline(char *line) +static inline void scr_cmdhisto_addline(char *line) { int max_histo_lines;