ports/databases/mysql56-server/files/patch-sql-common_client__authentication.cc
Jan Beich 511f6cbe19 databases/mysql56-server: unbreak build with Clang 6 (C++14 by default)
sql-common/client_authentication.cc:87:56: error: comparison between pointer and integer ('char *' and 'int')
      mysql->options.extension->server_public_key_path != '\0')
      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^  ~~~~

sql/sql_trigger.cc:195:5: error:
      non-constant-expression cannot be narrowed from type 'int' to 'size_t' (aka 'unsigned long') in
      initializer list [-Wc++11-narrowing]
    static_cast<int>(my_offsetof(class Table_triggers_list, definitions_list)),
    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Reported by:	antoine (via bug 224669)
2018-01-05 10:54:41 +00:00

17 lines
816 B
C++

sql-common/client_authentication.cc:87:56: error: comparison between pointer and integer ('char *' and 'int')
mysql->options.extension->server_public_key_path != '\0')
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ^ ~~~~
Part of https://github.com/mysql/mysql-server/commit/db1bde79b1b4
--- sql-common/client_authentication.cc.orig 2017-09-13 15:49:17 UTC
+++ sql-common/client_authentication.cc
@@ -84,7 +84,7 @@ RSA *rsa_init(MYSQL *mysql)
if (mysql->options.extension != NULL &&
mysql->options.extension->server_public_key_path != NULL &&
- mysql->options.extension->server_public_key_path != '\0')
+ mysql->options.extension->server_public_key_path[0] != '\0')
{
pub_key_file= fopen(mysql->options.extension->server_public_key_path,
"r");