| 516 | */ |
| 517 | |
| 518 | static int |
| 519 | insert_server_record_into_cache(FOREIGN_SERVER *server) |
| 520 | { |
| 521 | int error=0; |
| 522 | DBUG_ENTER("insert_server_record_into_cache"); |
| 523 | /* |
| 524 | We succeeded in insertion of the server to the table, now insert |
| 525 | the server to the cache |
| 526 | */ |
| 527 | DBUG_PRINT("info", ("inserting server %s at %p, length %zd", |
| 528 | server->server_name, server, |
| 529 | server->server_name_length)); |
| 530 | if (my_hash_insert(&servers_cache, (uchar*) server)) |
| 531 | { |
| 532 | DBUG_PRINT("info", ("had a problem inserting server %s at %p", |
| 533 | server->server_name, server)); |
| 534 | // error handling needed here |
| 535 | error= 1; |
| 536 | } |
| 537 | DBUG_RETURN(error); |
| 538 | } |
| 539 | |
| 540 | |
| 541 | /* |
no test coverage detected