Bug 461848 - libjar wince cleanup r+sr=dveditz
--- a/modules/libjar/nsZipArchive.cpp
+++ b/modules/libjar/nsZipArchive.cpp
@@ -98,16 +98,33 @@ char * strdup(const char *src)
{
long len = strlen(src);
char *dup = (char *)malloc(len+1 * sizeof(char));
memcpy(dup, src, len+1);
return dup;
}
#endif
+#ifdef WINCE
+int remove(const char* inPath)
+{
+ unsigned short wPath[MAX_PATH];
+ MultiByteToWideChar(CP_ACP,
+ 0,
+ inPath,
+ -1,
+ wPath,
+ MAX_PATH);
+
+ if(FALSE != DeleteFileW(wPath))
+ return 0;
+ return -1;
+}
+#endif
+
#endif /* STANDALONE */
#ifdef XP_UNIX
#include <sys/types.h>
#include <sys/stat.h>
#include <limits.h>
#include <unistd.h>
#elif defined(XP_WIN) || defined(XP_OS2)