• unknown's avatar
    Fixed BUG#13510: Setting password local variable changes current password · 71c89622
    unknown authored
      Disallow conflicting use of variables named "password" and "names". If such
      a variable is declared, and "SET ... = ..." is used for them, an error is
      returned; the user must resolve the conflict by either using `var` (indicating
      that the local variable is set) or by renaming the variable.
      This is necessary since setting "password" and "names" are treated as special
      cases by the parser.
    
    
    mysql-test/r/sp-error.result:
      New test cases for BUG#13510
    mysql-test/t/sp-error.test:
      New test cases for BUG#13510
    sql/share/errmsg.txt:
      New error message for when certain variable names are use which would be
      parsed the wrong way. (E.g. "password" and "names")
    sql/sql_yacc.yy:
      Check if "names" or "password" are used as local variable/parameter, in which
      case "set names" or "set password" will be parsed the wrong way. Give an error
      message instead.
    71c89622
errmsg.txt 322 KB