Skip to content

Commit

Permalink
post-merge: -Werror fixes in 10.2
Browse files Browse the repository at this point in the history
  • Loading branch information
vuvova committed Mar 29, 2019
1 parent f2a0c75 commit cc71e75
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 9 deletions.
5 changes: 5 additions & 0 deletions cmake/mariadb_connector_c.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -37,3 +37,8 @@ SET(CLIENT_PLUGIN_PVIO_SOCKET STATIC)

MESSAGE("== Configuring MariaDB Connector/C")
ADD_SUBDIRECTORY(libmariadb)

#remove after merging libmariadb > v3.0.9
IF(TARGET caching_sha2_password AND CMAKE_C_FLAGS_DEBUG MATCHES "-Werror")
SET_PROPERTY(TARGET caching_sha2_password APPEND_STRING PROPERTY COMPILE_FLAGS -Wno-unused-function)
ENDIF()
12 changes: 6 additions & 6 deletions sql/spatial.cc
Original file line number Diff line number Diff line change
Expand Up @@ -238,17 +238,17 @@ int Geometry::as_wkt(String *wkt, const char **end)


static const uchar type_keyname[]= "type";
static const int type_keyname_len= 4;
static const uint type_keyname_len= 4;
static const uchar coord_keyname[]= "coordinates";
static const int coord_keyname_len= 11;
static const uint coord_keyname_len= 11;
static const uchar geometries_keyname[]= "geometries";
static const int geometries_keyname_len= 10;
static const uint geometries_keyname_len= 10;
static const uchar features_keyname[]= "features";
static const int features_keyname_len= 8;
static const uint features_keyname_len= 8;
static const uchar geometry_keyname[]= "geometry";
static const int geometry_keyname_len= 8;
static const uint geometry_keyname_len= 8;

static const int max_keyname_len= 11; /*'coordinates' keyname is the longest.*/
static const uint max_keyname_len= 11; /*'coordinates' keyname is the longest.*/

static const uchar feature_type[]= "feature";
static const int feature_type_len= 7;
Expand Down
2 changes: 1 addition & 1 deletion storage/innobase/buf/buf0dump.cc
Original file line number Diff line number Diff line change
Expand Up @@ -392,7 +392,7 @@ buf_dump(
if (SHUTTING_DOWN() && !(j % 1024)) {
service_manager_extend_timeout(INNODB_EXTEND_TIMEOUT_INTERVAL,
"Dumping buffer pool "
ULINTPF "/" ULINTPF ", "
ULINTPF "/%lu, "
"page " ULINTPF "/" ULINTPF,
i + 1, srv_buf_pool_instances,
j + 1, n_pages);
Expand Down
4 changes: 2 additions & 2 deletions strings/json_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -1409,7 +1409,7 @@ int json_find_paths_next(json_engine_t *je, json_find_paths_t *state)
if (!json_key_matches(je, &key_name))
continue;
}
if (cur_step - state->paths[p_c].last_step == state->cur_depth)
if (cur_step == state->paths[p_c].last_step + state->cur_depth)
path_found= TRUE;
else
{
Expand Down Expand Up @@ -1442,7 +1442,7 @@ int json_find_paths_next(json_engine_t *je, json_find_paths_t *state)
cur_step->n_item == state->array_counters[state->cur_depth])
{
/* Array item matches. */
if (cur_step - state->paths[p_c].last_step == state->cur_depth)
if (cur_step == state->paths[p_c].last_step + state->cur_depth)
path_found= TRUE;
else
{
Expand Down

0 comments on commit cc71e75

Please sign in to comment.