[Nagiosplug-devel] error: redeclaration of enumerator 'OK'
Dustin Little
dlittle at toyatech.net
Wed Mar 18 23:02:18 CET 2009
Hello,
I began a rewriting the third party check_sap plugins several months ago
to use the new RFC libraries from SAP as well as other improvements. I
got bogged down after running into a conflict with the enumeration 'OK'
in common.h. The SAP library also declares an enumeration 'OK' which
results in an "error: redeclaration of enumerator 'OK'" when I compile.
I've attempted several work arounds such as wrapping the common.h
functionality or undefining OK before I reference the SAP header,
neither have resulted in much success. Wouldn't a better practice in a
language without namespaces be to use a prefix like 'NAGIOS_OK' to avoid
conflict? Has anyone encounter a similar conflict and found a resolution.
Thanks,
Dusty
More information about the Devel
mailing list