Closed Bug 461858 Opened 17 years ago Closed 16 years ago

windows mobile minor cleanup of xulrunner

Categories

(Toolkit Graveyard :: XULRunner, defect)

x86
Windows XP
defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: dougt, Assigned: blassey)

Details

(Keywords: fixed1.9.1)

Attachments

(1 file, 3 obsolete files)

we removed much of the functionality in the windows ce shunt library. This minor patch allows us to continue to build.
Attached patch patch v.1 (obsolete) — Splinter Review
Assignee: nobody → doug.turner
Attached patch patch v.2 (obsolete) — Splinter Review
Attachment #344991 - Attachment is obsolete: true
Attachment #346494 - Flags: superreview?(benjamin)
Attachment #346494 - Flags: review?(blassey)
Comment on attachment 346494 [details] [diff] [review] patch v.2 >diff --git a/toolkit/xre/nsUpdateDriver.cpp b/toolkit/xre/nsUpdateDriver.cpp >@@ -473,7 +475,9 @@ ApplyUpdate(nsIFile *greDir, nsIFile *up > chdir(applyToDir.get()); > execv(updaterPath.get(), argv); > #elif defined(XP_WIN) >+#ifndef WINCE > _wchdir(applyToDir.get()); >+#endif You don't put in any replacement function here... I'm sure the update driver isn't going to work without some additional patches, since it uses opens files on paths such as components/nsFoo.js. Please don't commit this file. I think we should just --disable-updater on WinCE until this can be fixed, and make sure that there's a bug filed about actually fixing it. >diff --git a/toolkit/xre/nsXREDirProvider.cpp b/toolkit/xre/nsXREDirProvider.cpp >@@ -916,7 +920,11 @@ nsXREDirProvider::GetUpdateRootDir(nsIFi > PRUint32 bufLength = longPath.GetMutableData(&buf, MAXPATHLEN); > NS_ENSURE_TRUE(bufLength >= MAXPATHLEN, NS_ERROR_OUT_OF_MEMORY); > >+#ifndef WINCE > DWORD len = GetLongPathNameW(appPath.get(), buf, bufLength); >+#else >+ DWORD len = 0; >+#endif This is a confusing way of writing what you're actually doing. I'd prefer something like: #ifdef WINCE longPath = appPath; #else ... all that GetLongPathName code #endif >diff --git a/xulrunner/stub/nsXULStub.cpp b/xulrunner/stub/nsXULStub.cpp >--- a/xulrunner/stub/nsXULStub.cpp >+++ b/xulrunner/stub/nsXULStub.cpp >@@ -260,8 +262,11 @@ main(int argc, char **argv) > "%sxulrunner" XPCOM_FILE_PATH_SEPARATOR XPCOM_DLL, > iniPath); > >+#ifndef WINCE > greFound = (access(greDir, R_OK) == 0); >- >+#else >+ greFound = PR_TRUE; >+#endif This code means that WinCE will only ever load xulrunner from the application directory, never a system location. Is this what you really mean to be doing? (I hope not.) If access() isn't implemented on WinCE, we should use whatever other function checks for the existence of a directory.
Attachment #346494 - Flags: superreview?(benjamin) → superreview-
Attachment #346494 - Attachment is obsolete: true
Attachment #348032 - Flags: review?(benjamin)
Attachment #346494 - Flags: review?(blassey)
Attachment #348032 - Attachment is obsolete: true
Attachment #348073 - Flags: review?(benjamin)
Attachment #348032 - Flags: review?(benjamin)
Assignee: doug.turner → blassey
Comment on attachment 348073 [details] [diff] [review] switched to use wide version >diff --git a/toolkit/xre/nsAppRunner.cpp b/toolkit/xre/nsAppRunner.cpp >diff --git a/xulrunner/stub/nsXULStub.cpp b/xulrunner/stub/nsXULStub.cpp >+#ifdef WINCE >+ DWORD fileAttrs = GetFileAttributesW(NS_ConvertUTF8toUTF16(greDir).get()); >+ greFound = fileAttrs != 0xFFFFFFFF && fileAttrs | FILE_ATTRIBUTE_DIRECTORY; As with the other bug, I think you want the symbolic INVALID_FILE_ATTRIBUTES instead of the magic constant here. r=me with that change.
Attachment #348073 - Flags: review?(benjamin) → review+
Status: NEW → RESOLVED
Closed: 16 years ago
Resolution: --- → FIXED
Attachment #348073 - Flags: approval1.9.1?
Comment on attachment 348073 [details] [diff] [review] switched to use wide version a191=beltzner
Attachment #348073 - Flags: approval1.9.1? → approval1.9.1+
this landed on the 1.9.1 branch. adding keyword fixed1.9.1
Keywords: fixed1.9.1
+ greFound = fileAttrs != INVALID_FILE_ATTRIBUTES && + fileAttrs | FILE_ATTRIBUTE_DIRECTORY; fileAttrs | FILE_ATTRIBUTE_DIRECTORY is always true, I guess you meant fileAttrs & FILE_ATTRIBUTE_DIRECTORY.
Product: Toolkit → Toolkit Graveyard
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: