diff options
author | tomas@poseidon.ndb.mysql.com <> | 2005-07-12 20:01:22 +0200 |
---|---|---|
committer | tomas@poseidon.ndb.mysql.com <> | 2005-07-12 20:01:22 +0200 |
commit | 674b6bb15140673107bacb1574e8e26f51ff002e (patch) | |
tree | 8fd7b30e9e4cce3fdfc60e700fdb2d668f2f6449 /sql/sql_acl.h | |
parent | 9743190cd90c7a51dfb23d5cbdca4b04fb7e6ae0 (diff) | |
parent | e06e06ffeb8dbcd2737720be9f78c5fe75b9c0f5 (diff) | |
download | mariadb-git-674b6bb15140673107bacb1574e8e26f51ff002e.tar.gz |
Merge
Diffstat (limited to 'sql/sql_acl.h')
-rw-r--r-- | sql/sql_acl.h | 11 |
1 files changed, 9 insertions, 2 deletions
diff --git a/sql/sql_acl.h b/sql/sql_acl.h index 87280c4e9ba..5e62e7ce6e3 100644 --- a/sql/sql_acl.h +++ b/sql/sql_acl.h @@ -107,8 +107,15 @@ (((A) & DB_CHUNK2) >> 6) | \ (((A) & DB_CHUNK3) >> 9) | \ (((A) & DB_CHUNK4) >> 2)) -#define fix_rights_for_table(A) (((A) & 63) | (((A) & ~63) << 4)) -#define get_rights_for_table(A) (((A) & 63) | (((A) & ~63) >> 4)) +#define TBL_CHUNK0 DB_CHUNK0 +#define TBL_CHUNK1 DB_CHUNK1 +#define TBL_CHUNK2 (CREATE_VIEW_ACL | SHOW_VIEW_ACL) +#define fix_rights_for_table(A) (((A) & TBL_CHUNK0) | \ + (((A) << 4) & TBL_CHUNK1) | \ + (((A) << 11) & TBL_CHUNK2)) +#define get_rights_for_table(A) (((A) & TBL_CHUNK0) | \ + (((A) & TBL_CHUNK1) >> 4) | \ + (((A) & TBL_CHUNK2) >> 11)) #define fix_rights_for_column(A) (((A) & 7) | (((A) & ~7) << 8)) #define get_rights_for_column(A) (((A) & 7) | ((A) >> 8)) #define fix_rights_for_procedure(A) ((((A) << 18) & EXECUTE_ACL) | \ |