[CONC-643] Fix for CONC-624 broke support for C++03 Created: 2023-04-11  Updated: 2023-05-02  Resolved: 2023-05-02

Status: Closed
Project: MariaDB Connector/C
Component/s: API
Affects Version/s: 3.1.20
Fix Version/s: 3.1.21, 3.3.5

Type: Bug Priority: Major
Reporter: David Ritter Assignee: Georg Richter
Resolution: Fixed Votes: 0
Labels: None
Environment:

C++03


Issue Links:
Problem/Incident
is caused by CONC-624 Macro SET_CLIENT_STMT_ERROR doesn't s... Closed

 Description   

With the fix for CONC-624, usage of an anonymous variadic macro was introduced to the MariaDB 3.1.x code base, which has the effect of now requiring C++11 or newer (as C++03 does not support anonymous variadic macros)

This results in the following compilation warning/error when using C++03

usr/include/mysql/mariadb_stmt.h:37:43: warning: anonymous variadic macros were introduced in C++11 [-Wvariadic-macros]
   37 | #define SET_CLIENT_STMT_ERROR(a, b, c, d, ...) \
      |                                           ^~~

It is unclear if this change to break support (I'm assuming as the client used to compile cleanly this is a break) was intentional or not.



 Comments   
Comment by Georg Richter [ 2023-05-02 ]

fixed by
commit 2000b06183bfda39f1a56ffcba1ceb3a3e9c2952
Replace SET_CLIENT_STMT_ERROR by stmt_set_error().

Generated at Thu Feb 08 03:06:47 UTC 2024 using Jira 8.20.16#820016-sha1:9d11dbea5f4be3d4cc21f03a88dd11d8c8687422.