Commit e2a8a99d authored by monty@donna.mysql.com's avatar monty@donna.mysql.com

Lots of manual changes

Changed 'static inline' to 'inline' for SCO new's compiler
parent 21185c17
This diff is collapsed.
......@@ -83,7 +83,7 @@ void hash_free(HASH *hash)
/* some helper functions */
static inline byte*
inline byte*
hash_key(HASH *hash,const byte *record,uint *length,my_bool first)
{
if (hash->get_key)
......@@ -180,7 +180,7 @@ uint calc_hashnr_caseup(const byte *key, uint len)
#endif
static inline uint rec_hashnr(HASH *hash,const byte *record)
inline uint rec_hashnr(HASH *hash,const byte *record)
{
uint length;
byte *key=hash_key(hash,record,&length,0);
......
......@@ -100,7 +100,7 @@ static void add_hostname(struct in_addr *in,const char *name)
}
static inline void add_wrong_ip(struct in_addr *in)
inline void add_wrong_ip(struct in_addr *in)
{
add_hostname(in,NullS);
}
......
......@@ -471,7 +471,7 @@ bool Item_real::save_in_field(Field *field)
** In number context this is a longlong value.
****************************************************************************/
static inline uint char_val(char X)
inline uint char_val(char X)
{
return (uint) (X >= '0' && X <= '9' ? X-'0' :
X >= 'A' && X <= 'Z' ? X-'A'+10 :
......
......@@ -74,7 +74,7 @@ typedef my_bool ALARM;
#define thr_alarm_in_use(A) (*(A))
#define thr_end_alarm(A)
#define thr_alarm(A,B,C) local_thr_alarm((A),(B),(C))
static inline int local_thr_alarm(my_bool *A,int B __attribute__((unused)),ALARM *C __attribute__((unused)))
inline int local_thr_alarm(my_bool *A,int B __attribute__((unused)),ALARM *C __attribute__((unused)))
{
*A=1;
return 0;
......
......@@ -91,7 +91,7 @@ void make_scrambled_password(char *to,const char *password)
sprintf(to,"%08lx%08lx",hash_res[0],hash_res[1]);
}
static inline uint char_val(char X)
inline uint char_val(char X)
{
return (uint) (X >= '0' && X <= '9' ? X-'0' :
X >= 'A' && X <= 'Z' ? X-'A'+10 :
......
......@@ -45,8 +45,8 @@ static int stuck_count = 0;
#endif
static inline void skip_load_data_infile(NET* net);
static inline bool slave_killed(THD* thd);
inline void skip_load_data_infile(NET* net);
inline bool slave_killed(THD* thd);
static int init_slave_thread(THD* thd);
static int safe_connect(THD* thd, MYSQL* mysql, MASTER_INFO* mi);
static int safe_reconnect(THD* thd, MYSQL* mysql, MASTER_INFO* mi);
......@@ -54,7 +54,7 @@ static int safe_sleep(THD* thd, int sec);
static int request_table_dump(MYSQL* mysql, char* db, char* table);
static int create_table_from_dump(THD* thd, NET* net, const char* db,
const char* table_name);
static inline char* rewrite_db(char* db);
inline char* rewrite_db(char* db);
static void free_table_ent(TABLE_RULE_ENT* e)
{
my_free((gptr) e, MYF(0));
......@@ -194,12 +194,12 @@ void end_slave()
free_string_array(&replicate_wild_ignore_table);
}
static inline bool slave_killed(THD* thd)
inline bool slave_killed(THD* thd)
{
return abort_slave || abort_loop || thd->killed;
}
static inline void skip_load_data_infile(NET* net)
inline void skip_load_data_infile(NET* net)
{
(void)my_net_write(net, "\xfb/dev/null", 10);
(void)net_flush(net);
......@@ -207,7 +207,7 @@ static inline void skip_load_data_infile(NET* net)
send_ok(net); // the master expects it
}
static inline char* rewrite_db(char* db)
inline char* rewrite_db(char* db)
{
if(replicate_rewrite_db.is_empty() || !db) return db;
I_List_iterator<i_string_pair> it(replicate_rewrite_db);
......
......@@ -1287,7 +1287,7 @@ static GRANT_TABLE *table_hash_search(const char *host,const char* ip,
static inline GRANT_COLUMN *
inline GRANT_COLUMN *
column_hash_search(GRANT_TABLE *t, const char *cname,
uint length)
{
......
......@@ -187,7 +187,8 @@ query_table_status(THD *thd,const char *db,const char *table_name)
** Sum fields has table name empty and field_name.
** flag is a bit mask with the following functions:
** 1 send number of rows
** 2 send default values; Don't convert field names
** 2 send default values
** 4 Don't convert field names
******************************************************************************/
bool
......@@ -196,7 +197,7 @@ send_fields(THD *thd,List<Item> &list,uint flag)
List_iterator<Item> it(list);
Item *item;
char buff[80];
CONVERT *convert= (flag & 2) ? (CONVERT*) 0 : thd->convert_set;
CONVERT *convert= (flag & 4) ? (CONVERT*) 0 : thd->convert_set;
String tmp((char*) buff,sizeof(buff)),*res,*packet= &thd->packet;
......
......@@ -71,7 +71,7 @@ static void init_signals(void)
}
#endif
static inline bool end_active_trans(THD *thd)
inline bool end_active_trans(THD *thd)
{
int error=0;
if (thd->options & (OPTION_NOT_AUTO_COMMIT | OPTION_BEGIN))
......@@ -496,7 +496,7 @@ end:
}
static inline void free_items(THD *thd)
inline void free_items(THD *thd)
{
/* This works because items are allocated with sql_alloc() */
for (Item *item=thd->free_list ; item ; item=item->next)
......
......@@ -237,7 +237,7 @@ binlog purge"; break;
break;
case LOG_INFO_MEM: errmsg = "Out of memory"; break;
case LOG_INFO_FATAL: errmsg = "Fatal error during purge"; break;
case LOG_INFO_IN_USE: errmsg = "A purgable log is in use, will not purge";
case LOG_INFO_IN_USE: errmsg = "A purgeable log is in use, will not purge";
break;
default:
errmsg = "Unknown error during purge"; break;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment