Skip to content

Commit 7ce1877

Browse files
gkodinovnawazn
authored andcommitted
WL#15766: Deprecate automatic reconnecton in the C API
Issue deprecation warning to stderr on mysql_options() and mysql_get_option(). Re-recorded the MEB tests Re-recorded some more MEB tests Re-recorded some even more MEB tests Re-recorded some further MEB tests Re-recorded windows only tests Change-Id: I5e7cb556779797ca7585daf000608046c3010608
1 parent 3260a7c commit 7ce1877

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

sql-common/client.cc

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8508,6 +8508,9 @@ int STDCALL mysql_options(MYSQL *mysql, enum mysql_option option,
85088508
mysql->options.report_data_truncation = *static_cast<const bool *>(arg);
85098509
break;
85108510
case MYSQL_OPT_RECONNECT:
8511+
fprintf(stderr,
8512+
"WARNING: MYSQL_OPT_RECONNECT is deprecated and will be "
8513+
"removed in a future version.\n");
85118514
mysql->reconnect = *static_cast<const bool *>(arg);
85128515
break;
85138516
case MYSQL_OPT_BIND:
@@ -8830,6 +8833,9 @@ int STDCALL mysql_get_option(MYSQL *mysql, enum mysql_option option,
88308833
mysql->options.report_data_truncation;
88318834
break;
88328835
case MYSQL_OPT_RECONNECT:
8836+
fprintf(stderr,
8837+
"WARNING: MYSQL_OPT_RECONNECT is deprecated and will be "
8838+
"removed in a future version.\n");
88338839
*(const_cast<bool *>(static_cast<const bool *>(arg))) = mysql->reconnect;
88348840
break;
88358841
case MYSQL_OPT_BIND:

0 commit comments

Comments
 (0)