~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to drizzled/charset.cc

  • Committer: Mark Atwood
  • Date: 2011-11-11 18:23:18 UTC
  • mfrom: (2456.1.5 rf)
  • Revision ID: me@mark.atwood.name-20111111182318-skgcp9ce65fd2goa
mergeĀ lp:~olafvdspek/drizzle/refactor11

Show diffs side-by-side

added added

removed removed

Lines of Context:
69
69
 
70
70
static uint get_collation_number_internal(const char *name)
71
71
{
72
 
  for (charset_info_st **cs= all_charsets;
73
 
       cs < all_charsets+array_elements(all_charsets)-1;
74
 
       cs++)
 
72
  for (charset_info_st **cs= all_charsets; cs < all_charsets + array_elements(all_charsets) - 1; cs++)
75
73
  {
76
 
    if ( cs[0] && cs[0]->name && !my_strcasecmp(&my_charset_utf8_general_ci, cs[0]->name, name))
 
74
    if (cs[0] && cs[0]->name && not my_charset_utf8_general_ci.strcasecmp(cs[0]->name, name))
77
75
    {
78
76
      return cs[0]->number;
79
77
    }
220
218
 
221
219
uint32_t get_charset_number(const char *charset_name, uint32_t cs_flags)
222
220
{
223
 
  charset_info_st **cs;
224
221
  init_available_charsets();
225
222
 
226
 
  for (cs= all_charsets;
227
 
       cs < all_charsets+array_elements(all_charsets)-1 ;
228
 
       cs++)
 
223
  for (charset_info_st** cs= all_charsets; cs < all_charsets + array_elements(all_charsets) - 1; cs++)
229
224
  {
230
 
    if ( cs[0] && cs[0]->csname && (cs[0]->state & cs_flags) && !my_strcasecmp(&my_charset_utf8_general_ci, cs[0]->csname, charset_name))
 
225
    if (cs[0] && cs[0]->csname && (cs[0]->state & cs_flags) && not my_charset_utf8_general_ci.strcasecmp(cs[0]->csname, charset_name))
231
226
      return cs[0]->number;
232
227
  }
233
228
  return 0;