laurencelundblade / QCBOR

Comprehensive, powerful, commercial-quality CBOR encoder/ decoder that is still suited for small devices.
Other
183 stars 47 forks source link

Add missing extern C block in qcbor_common.h #177

Closed plietar closed 1 year ago

plietar commented 1 year ago

Without this, C++ applications which include this header file will give functions defined in it, namely qcbor_err_to_str, a C++ linkage. This will cause linking to fail, since the compiled QCBOR library would have a C linkage only.

Other header files already have this extern block, it was only missing from qcbor_common.h for no particular reason.

laurencelundblade commented 1 year ago

It was absent intentionally, because I thought there were no function definitions. Missed the the error string function. Will merge soon.