X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/e6ed776fb2d330b4b6d0105c3628ccf88fd3bb60..a92b0cfd2bd0bef75b43c071df0b0e028f360d8e:/src/xpm/misc.c?ds=sidebyside diff --git a/src/xpm/misc.c b/src/xpm/misc.c index 7a9ecb58ae..b8c704b795 100644 --- a/src/xpm/misc.c +++ b/src/xpm/misc.c @@ -39,9 +39,14 @@ * in case strdup is not provided by the system here is one * which does the trick */ +#ifdef __OS2__ +/* Visual Age cannot deal with old, non-ansi, code */ +char* xpmstrdup(char* s1) +#else char * xpmstrdup(s1) char *s1; +#endif { char *s2; int l = strlen(s1) + 1; @@ -53,11 +58,21 @@ xpmstrdup(s1) #endif +#ifdef __OS2__ +/* Visual Age cannot deal with old, non-ansi, code */ +unsigned int +xpmatoui( + register char* p +, unsigned int l +, unsigned int* ui_return +) +#else unsigned int xpmatoui(p, l, ui_return) register char *p; unsigned int l; unsigned int *ui_return; +#endif { register unsigned int n, i; @@ -78,9 +93,14 @@ xpmatoui(p, l, ui_return) /* * Function returning a character string related to an error code. */ +#ifdef __OS2__ +/* Visual Age cannot deal with old, non-ansi, code */ +char* XpmGetErrorString(int errcode) +#else char * XpmGetErrorString(errcode) int errcode; +#endif { switch (errcode) { case XpmColorError: @@ -116,9 +136,15 @@ XpmLibraryVersion() #undef XpmFree #endif +#ifdef __OS2__ +/* Visual Age cannot deal with old, non-ansi, code */ +void +XpmFree(void* ptr) +#else void XpmFree(ptr) void *ptr; +#endif { free(ptr); }