Fixed to Coverity defects and a fix to tee filter not compiling with SS_DEBUG flag.

This commit is contained in:
Markus Makela
2015-03-07 06:00:01 +02:00
parent dc1829fc8a
commit ea039dd01a
12 changed files with 50 additions and 39 deletions

View File

@ -1228,8 +1228,8 @@ MYSQL_session *auth_info;
if ((auth_info = calloc(1, sizeof(MYSQL_session))) == NULL)
return NULL;
strcpy(auth_info->user, username);
strcpy(auth_info->db, database);
strncpy(auth_info->user, username,MYSQL_USER_MAXLEN+1);
strncpy(auth_info->db, database,MYSQL_DATABASE_MAXLEN+1);
gw_sha1_str((const uint8_t *)password, strlen(password), auth_info->client_sha1);
return auth_info;