~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to sql/item_strfunc.cc

  • Committer: Stewart Smith
  • Date: 2008-07-08 09:49:06 UTC
  • mto: (54.1.6 drizzle-smack)
  • mto: This revision was merged to the branch mainline in revision 111.
  • Revision ID: stewart@flamingspork.com-20080708094906-v66rmocdte3txwxv
remove old_password support from server (patch 1)

removes OLD_PASSWORD function, variable, parser bits.

need to still remove bits from protocol

Show diffs side-by-side

added added

removed removed

Lines of Context:
1324
1324
  return buff;
1325
1325
}
1326
1326
 
1327
 
/* Item_func_old_password */
1328
 
 
1329
 
String *Item_func_old_password::val_str(String *str)
1330
 
{
1331
 
  DBUG_ASSERT(fixed == 1);
1332
 
  String *res= args[0]->val_str(str);
1333
 
  if ((null_value=args[0]->null_value))
1334
 
    return 0;
1335
 
  if (res->length() == 0)
1336
 
    return &my_empty_string;
1337
 
  make_scrambled_password_323(tmp_value, res->c_ptr());
1338
 
  str->set(tmp_value, SCRAMBLED_PASSWORD_CHAR_LENGTH_323, res->charset());
1339
 
  return str;
1340
 
}
1341
 
 
1342
 
char *Item_func_old_password::alloc(THD *thd, const char *password)
1343
 
{
1344
 
  char *buff= (char *) thd->alloc(SCRAMBLED_PASSWORD_CHAR_LENGTH_323+1);
1345
 
  if (buff)
1346
 
    make_scrambled_password_323(buff, password);
1347
 
  return buff;
1348
 
}
1349
 
 
1350
 
 
1351
1327
#define bin_to_ascii(c) ((c)>=38?((c)-38+'a'):(c)>=12?((c)-12+'A'):(c)+'.')
1352
1328
 
1353
1329
String *Item_func_encrypt::val_str(String *str)