[Scummvm-cvs-logs] CVS: scummvm/backends/wince/missing missing.cpp,1.5,1.6
Nicolas Bacca
arisme at users.sourceforge.net
Sun May 11 07:03:07 CEST 2003
Update of /cvsroot/scummvm/scummvm/backends/wince/missing
In directory sc8-pr-cvs1:/tmp/cvs-serv14752
Modified Files:
missing.cpp
Log Message:
Update missing functions for HPC builds
Index: missing.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/backends/wince/missing/missing.cpp,v
retrieving revision 1.5
retrieving revision 1.6
diff -u -d -r1.5 -r1.6
--- missing.cpp 4 Apr 2003 13:11:32 -0000 1.5
+++ missing.cpp 11 May 2003 14:02:18 -0000 1.6
@@ -242,7 +242,11 @@
}
+#if _WIN32_WCE < 300
+char *_strdup(const char *strSource)
+#else
char *strdup(const char *strSource)
+#endif
{
char* buffer;
buffer = (char*)malloc(strlen(strSource)+1);
@@ -391,10 +395,6 @@
#if _WIN32_WCE < 300 || defined(_TEST_HPC_STDIO)
-int _heapchk() {
- return _HEAPOK;
-}
-
void *calloc(size_t n, size_t s) {
void *result = malloc(n * s);
if (result)
@@ -403,6 +403,22 @@
return result;
}
+char *strpbrk(const char *s, const char *accept) {
+ int i;
+
+ if (!s || !accept)
+ return NULL;
+
+ for (i=0; i<strlen(s); i++) {
+ int j;
+ for (j=0; j<strlen(accept); j++)
+ if (s[i] == accept[j])
+ return (char*)&s[i];
+ }
+
+ return NULL;
+}
+
#ifndef _TEST_HPC_STDIO
int isdigit(int c) {
@@ -419,6 +435,9 @@
#endif
+#ifndef WIN32_PLATFORM_HPCPRO
+
+
int printf(const char *format, ...) {
// useless anyway :)
return 0;
@@ -533,15 +552,7 @@
return 0;
}
-void assert (int expression) {
- if (!expression)
- abort();
-}
-
-void assert (void *expression) {
- if (!expression)
- abort();
-}
+#endif
int stricmp( const char *string1, const char *string2 ) {
char src[4096];
@@ -563,10 +574,6 @@
dest[i] = 0;
return strcmp(src, dest);
-}
-
-int _stricmp( const char *string1, const char *string2 ) {
- return stricmp(string1, string2);
}
char *strrchr(const char *s, int c) {
More information about the Scummvm-git-logs
mailing list