Closed Bug 325450 Opened 15 years ago Closed 15 years ago
GREGlue check of GRE _HOME needs to add "/libxpcom .so"
nsGREGlue has a check for GRE_HOME (which should by tradition be a directory path), but the function should return a patch with the XPCOM DLL path.
Comment on attachment 216552 [details] [diff] [review] Fix GRE_HOME, rev. 1 >Index: xpcom/glue/nsGREGlue.cpp >+ char p[MAXPATHLEN]; >+ snprintf(p, sizeof(p), "%s" XPCOM_FILE_PATH_SEPARATOR XPCOM_DLL, env); >+ p[sizeof(p)] = '\0'; This is writing a null byte beyond the end of the array. snprintf promises to null terminate |p| or upon failure it will leave |p| unmodified. Perhaps you should initialize p to '\0' then. r=darin w/ that fixed
Attachment #216552 - Flags: review?(darin) → review+
Fixed on trunk. I'd like to fix this on the 1.8 branch as well, but not 1.8.0 as it is in a bizarre way an API that should remain stable.
Status: NEW → RESOLVED
Closed: 15 years ago
Resolution: --- → FIXED
Attachment #216552 - Flags: approval-branch-1.8.1?(darin)
Comment on attachment 216552 [details] [diff] [review] Fix GRE_HOME, rev. 1 a=darin
Attachment #216552 - Flags: approval-branch-1.8.1?(darin) → approval-branch-1.8.1+
Fixed on 1.8 branch.
You need to log in before you can comment on or make changes to this bug.