1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-15091 : Windows, 64bit: reenable and fix warning C4267 (conversion from 'size_t' to 'type', possible loss of data)

Handle string length as size_t, consistently (almost always:))
Change function prototypes to accept size_t, where in the past
ulong or uint were used. change local/member variables to size_t
when appropriate.

This fix excludes rocksdb, spider,spider, sphinx and connect for now.
This commit is contained in:
Vladislav Vaintroub
2018-02-06 12:55:58 +00:00
parent f271100836
commit 6c279ad6a7
257 changed files with 1514 additions and 1543 deletions

View File

@ -35,7 +35,7 @@
#include <mysys_err.h>
LEX_CSTRING *make_lex_string(LEX_CSTRING *lex_str,
const char* str, uint length,
const char* str, size_t length,
MEM_ROOT *mem_root)
{
if (!(lex_str->str= strmake_root(mem_root, str, length)))
@ -654,7 +654,7 @@ static void build_trig_stmt_query(THD *thd, TABLE_LIST *tables,
{
LEX_CSTRING stmt_definition;
LEX *lex= thd->lex;
uint prefix_trimmed, suffix_trimmed;
size_t prefix_trimmed, suffix_trimmed;
size_t original_length;
/*