00001
00016 #ifndef _DLR_PORTABILITY_STANDARDC_H_
00017 #define _DLR_PORTABILITY_STANDARDC_H_
00018
00019 #include <cstdio>
00020
00021 #ifdef _WIN32
00022
00023 #ifndef HAVE_SNPRINTF
00024 #define HAVE_SNPRINTF 0
00025 #endif
00026
00027 #else
00028
00029 #ifndef HAVE_SNPRINTF
00030 #define HAVE_SNPRINTF 1
00031 #endif
00032
00033 #endif
00034
00035 namespace dlr {
00036
00041 namespace portability {
00042
00043 #if HAVE_SNPRINTF
00044 using std::snprintf;
00045 #else
00046
00064 int snprintf(char* targetString, size_t targetSize, const char* format,
00065 ...);
00066
00067 #endif
00068
00069 }
00070
00071 }
00072
00073
00074
00075
00076 namespace dlr {
00077
00078 using portability::snprintf;
00079
00080 }
00081
00082 #endif