File tree Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Expand file tree Collapse file tree 1 file changed +4
-1
lines changed Original file line number Diff line number Diff line change @@ -618,7 +618,9 @@ enum _oursqlx_exception_type _oursqlx_exc_from_errno(int err) {
618
618
619
619
default :
620
620
#if MYSQL_VERSION_ID >= 50700
621
- for (unsigned int i = 0 ; i < sizeof (errmsg_section_start )/sizeof (int ); ++ i ) {
621
+ {
622
+ unsigned int i ;
623
+ for (i = 0 ; i < sizeof (errmsg_section_start )/sizeof (int ); ++ i ) {
622
624
int min = errmsg_section_start [i ];
623
625
int max = errmsg_section_start [i ] + errmsg_section_size [i ] - 1 ;
624
626
if ( err >= min && err <= max ) {
@@ -628,6 +630,7 @@ enum _oursqlx_exception_type _oursqlx_exc_from_errno(int err) {
628
630
if ( err > CR_MIN_ERROR && err < CR_MAX_ERROR ) {
629
631
return _oursqlx_InterfaceError ;
630
632
}
633
+ }
631
634
#else
632
635
if (err >= ER_ERROR_FIRST && err <= ER_ERROR_LAST )
633
636
return _oursqlx_ProgrammingError ;
You can’t perform that action at this time.
0 commit comments