Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
M
MariaDB
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
nexedi
MariaDB
Commits
8d413c32
Commit
8d413c32
authored
Oct 03, 2017
by
Vladislav Vaintroub
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix several truncation and formatting warnings.
parent
47327679
Changes
6
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
17 additions
and
17 deletions
+17
-17
sql/item_inetfunc.cc
sql/item_inetfunc.cc
+10
-10
sql/lock.cc
sql/lock.cc
+1
-1
sql/log.cc
sql/log.cc
+1
-1
sql/mf_iocache_encr.cc
sql/mf_iocache_encr.cc
+2
-2
sql/sql_parse.cc
sql/sql_parse.cc
+2
-2
sql/sql_window.cc
sql/sql_window.cc
+1
-1
No files found.
sql/item_inetfunc.cc
View file @
8d413c32
...
...
@@ -217,7 +217,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): "
"invalid IPv4 address: too short."
,
str_length
,
str
));
(
int
)
str_length
,
str
));
return
false
;
}
...
...
@@ -225,7 +225,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): "
"invalid IPv4 address: too long."
,
str_length
,
str
));
(
int
)
str_length
,
str
));
return
false
;
}
...
...
@@ -248,7 +248,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): invalid IPv4 address: "
"too many characters in a group."
,
str_length
,
str
));
(
int
)
str_length
,
str
));
return
false
;
}
...
...
@@ -258,7 +258,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): invalid IPv4 address: "
"invalid byte value."
,
str_length
,
str
));
(
int
)
str_length
,
str
));
return
false
;
}
}
...
...
@@ -268,7 +268,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): invalid IPv4 address: "
"too few characters in a group."
,
str_length
,
str
));
(
int
)
str_length
,
str
));
return
false
;
}
...
...
@@ -281,7 +281,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
if
(
dot_count
>
3
)
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): invalid IPv4 address: "
"too many dots."
,
str_length
,
str
));
"too many dots."
,
(
int
)
str_length
,
str
));
return
false
;
}
}
...
...
@@ -289,7 +289,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): invalid IPv4 address: "
"invalid character at pos %d."
,
str_length
,
str
,
(
int
)
(
p
-
str
)));
(
int
)
str_length
,
str
,
(
int
)
(
p
-
str
)));
return
false
;
}
}
...
...
@@ -297,7 +297,7 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
if
(
c
==
'.'
)
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): invalid IPv4 address: "
"ending at '.'."
,
str_length
,
str
));
"ending at '.'."
,
(
int
)
str_length
,
str
));
return
false
;
}
...
...
@@ -305,14 +305,14 @@ static bool str_to_ipv4(const char *str, size_t str_length, in_addr *ipv4_addres
{
DBUG_PRINT
(
"error"
,
(
"str_to_ipv4(%.*s): invalid IPv4 address: "
"too few groups."
,
str_length
,
str
));
(
int
)
str_length
,
str
));
return
false
;
}
ipv4_bytes
[
3
]
=
(
unsigned
char
)
byte_value
;
DBUG_PRINT
(
"info"
,
(
"str_to_ipv4(%.*s): valid IPv4 address: %d.%d.%d.%d"
,
str_length
,
str
,
(
int
)
str_length
,
str
,
ipv4_bytes
[
0
],
ipv4_bytes
[
1
],
ipv4_bytes
[
2
],
ipv4_bytes
[
3
]));
return
true
;
...
...
sql/lock.cc
View file @
8d413c32
...
...
@@ -824,7 +824,7 @@ MYSQL_LOCK *get_lock_data(THD *thd, TABLE **table_ptr, uint count, uint flags)
we may allocate too much, but better safe than memory overrun.
And in the FLUSH case, the memory is released quickly anyway.
*/
sql_lock
->
lock_count
=
locks
-
locks_buf
;
sql_lock
->
lock_count
=
(
uint
)(
locks
-
locks_buf
)
;
DBUG_ASSERT
(
sql_lock
->
lock_count
<=
lock_count
);
DBUG_PRINT
(
"info"
,
(
"sql_lock->table_count %d sql_lock->lock_count %d"
,
sql_lock
->
table_count
,
sql_lock
->
lock_count
));
...
...
sql/log.cc
View file @
8d413c32
...
...
@@ -1292,7 +1292,7 @@ bool LOGGER::slow_log_print(THD *thd, const char *query, uint query_length,
}
/* fill in user_host value: the format is "%s[%s] @ %s [%s]" */
user_host_len
=
(
strxnmov
(
user_host_buff
,
MAX_USER_HOST_SIZE
,
user_host_len
=
(
uint
)(
strxnmov
(
user_host_buff
,
MAX_USER_HOST_SIZE
,
sctx
->
priv_user
,
"["
,
sctx
->
user
?
sctx
->
user
:
(
thd
->
slave_thread
?
"SQL_SLAVE"
:
""
),
"] @ "
,
sctx
->
host
?
sctx
->
host
:
""
,
" ["
,
...
...
sql/mf_iocache_encr.cc
View file @
8d413c32
...
...
@@ -92,7 +92,7 @@ static int my_b_encr_read(IO_CACHE *info, uchar *Buffer, size_t Count)
DBUG_RETURN
(
1
);
}
elength
=
wlength
-
(
ebuffer
-
wbuffer
);
elength
=
wlength
-
(
uint
)(
ebuffer
-
wbuffer
);
set_iv
(
iv
,
pos_in_file
,
crypt_data
->
inbuf_counter
);
if
(
encryption_crypt
(
ebuffer
,
elength
,
info
->
buffer
,
&
length
,
...
...
@@ -184,7 +184,7 @@ static int my_b_encr_write(IO_CACHE *info, const uchar *Buffer, size_t Count)
my_errno
=
1
;
DBUG_RETURN
(
info
->
error
=
-
1
);
}
wlength
=
elength
+
ebuffer
-
wbuffer
;
wlength
=
elength
+
(
uint
)(
ebuffer
-
wbuffer
)
;
if
(
length
==
info
->
buffer_length
)
{
...
...
sql/sql_parse.cc
View file @
8d413c32
...
...
@@ -1484,8 +1484,8 @@ uint maria_multi_check(THD *thd, char *packet, uint packet_length)
size_t
subpacket_length
=
net_field_length
((
uchar
**
)
&
packet_start
);
size_t
length_length
=
packet_start
-
packet
;
// length of command + 3 bytes where that length was stored
DBUG_PRINT
(
"info"
,
(
"sub-packet length: %
ld + %d
command: %x"
,
(
ulong
)
subpacket_length
,
length_length
,
DBUG_PRINT
(
"info"
,
(
"sub-packet length: %
zu + %zu
command: %x"
,
subpacket_length
,
length_length
,
packet_start
[
3
]));
if
(
subpacket_length
==
0
||
...
...
sql/sql_window.cc
View file @
8d413c32
...
...
@@ -327,7 +327,7 @@ int compare_order_elements(ORDER *ord1, ORDER *ord2)
Item
*
item2
=
(
*
ord2
->
item
)
->
real_item
();
DBUG_ASSERT
(
item1
->
type
()
==
Item
::
FIELD_ITEM
&&
item2
->
type
()
==
Item
::
FIELD_ITEM
);
in
t
cmp
=
((
Item_field
*
)
item1
)
->
field
-
((
Item_field
*
)
item2
)
->
field
;
ptrdiff_
t
cmp
=
((
Item_field
*
)
item1
)
->
field
-
((
Item_field
*
)
item2
)
->
field
;
if
(
cmp
==
0
)
{
if
(
ord1
->
direction
==
ord2
->
direction
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment