• unknown's avatar
    Bug #20908: Crash if select @@"" · d126dd21
    unknown authored
    Zero-length variables caused failures when using the length to look
    up the name in a hash.  Instead, signal that no zero-length name can
    ever be found and that to encounter one is a syntax error.
    
    
    mysql-test/r/variables.result:
      Results for test.
    mysql-test/t/variables.test:
      Insert tests to prove that zero-length variable names do not cause
      faults.
    sql/gen_lex_hash.cc:
      If the length is zero, then there is nothing to look-up in the 
      hash.
    sql/sql_lex.cc:
      Names of variables must not be empty.  Signal an error of that 
      happens.
    d126dd21
variables.result 25.2 KB