summaryrefslogtreecommitdiff
path: root/sql/password.c
diff options
context:
space:
mode:
authordlenev@brandersnatch.localdomain <>2004-05-27 17:54:40 +0400
committerdlenev@brandersnatch.localdomain <>2004-05-27 17:54:40 +0400
commit03b705ff4408f011eebdadffeb249e9ef533c3ea (patch)
tree0a3ac45d591f6d81591a9b4ec19f2d45e2c29570 /sql/password.c
parentfc85c80b88c0717684184f22a91f8b027a8f8559 (diff)
downloadmariadb-git-03b705ff4408f011eebdadffeb249e9ef533c3ea.tar.gz
Made my_snprintf() behavior snprintf() compatible when printing %x arguments (it should
produce hex digits in lower case). (fixed version) Replaced _dig_vec array with two _dig_vec_upper/_dig_vec_lower arrays. Added extra argument to int2str function which controls case of digits you get. Replaced lot of invocations of int2str for decimal radix with more optimized int10_to_str() function. Removed unused my_itoa/my_ltoa functions.
Diffstat (limited to 'sql/password.c')
-rw-r--r--sql/password.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sql/password.c b/sql/password.c
index 9f4910d8c60..49f149969c9 100644
--- a/sql/password.c
+++ b/sql/password.c
@@ -321,8 +321,8 @@ octet2hex(char *to, const uint8 *str, uint len)
const uint8 *str_end= str + len;
for (; str != str_end; ++str)
{
- *to++= _dig_vec[(*str & 0xF0) >> 4];
- *to++= _dig_vec[*str & 0x0F];
+ *to++= _dig_vec_upper[(*str & 0xF0) >> 4];
+ *to++= _dig_vec_upper[*str & 0x0F];
}
*to= '\0';
}