Skip to content

Commit 13db625

Browse files
committed
Fix two compilation warnings/errors:
GCC 4.6.3 /sql/sql_acl.cc: In function 'int replace_user_table(THD*, TABLE*, LEX_USER*, ulong, bool, bool, bool)': /sql/sql_acl.cc:2701:8: error: variable 'sha2_plugin' set but not used [-Werror=unused-but-set-variable] Clang 4.1 /mysys_ssl/my_default.cc:930:15: warning: equality comparison with extraneous parentheses [-Wparentheses-equality]
1 parent 247ba65 commit 13db625

File tree

2 files changed

+1
-5
lines changed

2 files changed

+1
-5
lines changed

mysys_ssl/my_default.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -927,7 +927,7 @@ static int search_default_file_with_ext(Process_option_func opt_handler,
927927
continue;
928928

929929
/* Configuration File Directives */
930-
if ((*ptr == '!'))
930+
if (*ptr == '!')
931931
{
932932
if (recursion_level >= max_recursion_level)
933933
{

sql/sql_acl.cc

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2697,9 +2697,6 @@ static int replace_user_table(THD *thd, TABLE *table, LEX_USER *combo,
26972697
char what= (revoke_grant) ? 'N' : 'Y';
26982698
uchar user_key[MAX_KEY_LENGTH];
26992699
LEX *lex= thd->lex;
2700-
#if defined(HAVE_OPENSSL)
2701-
bool sha2_plugin= false;
2702-
#endif
27032700
DBUG_ENTER("replace_user_table");
27042701

27052702
mysql_mutex_assert_owner(&acl_cache->lock);
@@ -2902,7 +2899,6 @@ static int replace_user_table(THD *thd, TABLE *table, LEX_USER *combo,
29022899
#if defined(HAVE_OPENSSL)
29032900
if (combo->plugin.str == sha256_password_plugin_name.str)
29042901
{
2905-
sha2_plugin= true;
29062902
table->field[MYSQL_USER_FIELD_AUTHENTICATION_STRING]->
29072903
store(password, password_len, &my_charset_utf8_bin);
29082904
combo->auth.str= password;

0 commit comments

Comments
 (0)