Commit 72aef9c2 authored by unknown's avatar unknown
Browse files

Merge


include/violite.h:
  Auto merged
mysql-test/r/ps_7ndb.result:
  Auto merged
sql/sql_parse.cc:
  Auto merged
sql/sql_select.cc:
  Manual merge
parents 32ff7ade 633a2468
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -144,8 +144,8 @@ int vio_close_shared_memory(Vio * vio);
#if !defined(DONT_MAP_VIO)
#define vio_delete(vio) 			(vio)->viodelete(vio)
#define vio_errno(vio)	 			(vio)->vioerrno(vio)
#define vio_read(vio, buf, size) 		(vio)->read(vio,buf,size)
#define vio_write(vio, buf, size) 		(vio)->write(vio, buf, size)
#define vio_read(vio, buf, size)                ((vio)->read)(vio,buf,size)
#define vio_write(vio, buf, size)               ((vio)->write)(vio, buf, size)
#define vio_blocking(vio, set_blocking_mode, old_mode)\
 	(vio)->vioblocking(vio, set_blocking_mode, old_mode)
#define vio_is_blocking(vio) 			(vio)->is_blocking(vio)
+2 −2
Original line number Diff line number Diff line
drop table if exists t1;
SET NAMES cp1251;
create table t1 (a varchar(10) not null);
create table t1 (a varchar(10) not null) character set cp1251;
insert into t1 values ("a"),("ab"),("abc");
select * from t1;
a
@@ -23,7 +23,7 @@ a
b
c
drop table t1;
create table t1 (a char(15) binary, b binary(15));
create table t1 (a char(15) binary, b binary(15)) character set cp1251;
insert into t1 values ('aaa','bbb'),('AAA','BBB');
select upper(a),upper(b) from t1;
upper(a)	upper(b)
+0 −2
Original line number Diff line number Diff line
--default-character-set=cp1251 --new
+2 −2
Original line number Diff line number Diff line
@@ -10,7 +10,7 @@ SET NAMES cp1251;
# Test problem with LEFT() (Bug #514)
#

create table t1 (a varchar(10) not null);
create table t1 (a varchar(10) not null) character set cp1251;
insert into t1 values ("a"),("ab"),("abc");
select * from t1;
select a, left(a,1) as b from t1;
@@ -21,7 +21,7 @@ drop table t1;
#
# Test of binary and upper/lower
#
create table t1 (a char(15) binary, b binary(15));
create table t1 (a char(15) binary, b binary(15)) character set cp1251;
insert into t1 values ('aaa','bbb'),('AAA','BBB');
select upper(a),upper(b) from t1;
select lower(a),lower(b) from t1;
+5 −6
Original line number Diff line number Diff line
@@ -4579,6 +4579,7 @@ check_access(THD *thd, ulong want_access, const char *db, ulong *save_priv,
{
#ifndef NO_EMBEDDED_ACCESS_CHECKS
  ulong db_access;
  bool  db_is_pattern= test(want_access & GRANT_ACL);
#endif
  ulong dummy;
  DBUG_ENTER("check_access");
@@ -4610,9 +4611,8 @@ check_access(THD *thd, ulong want_access, const char *db, ulong *save_priv,
    */
    db_access= thd->db_access;
    if (!(thd->master_access & SELECT_ACL) &&
	(db && (!thd->db || strcmp(db,thd->db))))
      db_access=acl_get(thd->host, thd->ip,
			thd->priv_user, db, test(want_access & GRANT_ACL));
	(db && (!thd->db || db_is_pattern || strcmp(db,thd->db))))
      db_access=acl_get(thd->host, thd->ip, thd->priv_user, db, db_is_pattern);
    *save_priv=thd->master_access | db_access;
    DBUG_RETURN(FALSE);
  }
@@ -4633,9 +4633,8 @@ check_access(THD *thd, ulong want_access, const char *db, ulong *save_priv,
  if (db == any_db)
    DBUG_RETURN(FALSE);				// Allow select on anything

  if (db && (!thd->db || strcmp(db,thd->db)))
    db_access=acl_get(thd->host, thd->ip,
		      thd->priv_user, db, test(want_access & GRANT_ACL));
  if (db && (!thd->db || db_is_pattern || strcmp(db,thd->db)))
    db_access=acl_get(thd->host, thd->ip, thd->priv_user, db, db_is_pattern);
  else
    db_access=thd->db_access;
  DBUG_PRINT("info",("db_access: %lu", db_access));
Loading