diff options
author | Sergei Golubchik <sergii@pisem.net> | 2013-04-15 15:09:22 +0200 |
---|---|---|
committer | Sergei Golubchik <sergii@pisem.net> | 2013-04-15 15:09:22 +0200 |
commit | a9035be5b7a7b3865ddb4ef34a5d0cfc65dfc254 (patch) | |
tree | a9df7341e91623f62fe37cd47fce139d8888fc95 /client/mysqldump.c | |
parent | 3a1c91d87d69ef243b3e78be6089102cafef0a8e (diff) | |
parent | f57ecb7786177e0af3b1e3ec94302720b2e0f967 (diff) | |
download | mariadb-git-a9035be5b7a7b3865ddb4ef34a5d0cfc65dfc254.tar.gz |
10.0-base merge
Diffstat (limited to 'client/mysqldump.c')
-rw-r--r-- | client/mysqldump.c | 17 |
1 files changed, 2 insertions, 15 deletions
diff --git a/client/mysqldump.c b/client/mysqldump.c index 1cf66fe3dd1..c1e848b1752 100644 --- a/client/mysqldump.c +++ b/client/mysqldump.c @@ -2300,7 +2300,6 @@ static uint dump_routines_for_db(char *db) const char *routine_type[]= {"FUNCTION", "PROCEDURE"}; char db_name_buff[NAME_LEN*2+3], name_buff[NAME_LEN*2+3]; char *routine_name; - char *query_str; int i; FILE *sql_file= md_result_file; MYSQL_RES *routine_res, *routine_list_res; @@ -2394,17 +2393,6 @@ static uint dump_routines_for_db(char *db) fprintf(sql_file, "/*!50003 DROP %s IF EXISTS %s */;\n", routine_type[i], routine_name); - query_str= cover_definer_clause(row[2], strlen(row[2]), - C_STRING_WITH_LEN("50020"), - C_STRING_WITH_LEN("50003"), - C_STRING_WITH_LEN(" FUNCTION")); - - if (!query_str) - query_str= cover_definer_clause(row[2], strlen(row[2]), - C_STRING_WITH_LEN("50020"), - C_STRING_WITH_LEN("50003"), - C_STRING_WITH_LEN(" PROCEDURE")); - if (mysql_num_fields(routine_res) >= 6) { if (switch_db_collation(sql_file, db_name_buff, ";", @@ -2442,9 +2430,9 @@ static uint dump_routines_for_db(char *db) fprintf(sql_file, "DELIMITER ;;\n" - "/*!50003 %s */;;\n" + "%s ;;\n" "DELIMITER ;\n", - (const char *) (query_str != NULL ? query_str : row[2])); + (const char *) row[2]); restore_sql_mode(sql_file, ";"); @@ -2459,7 +2447,6 @@ static uint dump_routines_for_db(char *db) } } - my_free(query_str); } } /* end of routine printing */ mysql_free_result(routine_res); |