Open Bug 407445 Opened 12 years ago Updated 11 years ago
.pl treats "--object" address case-sensitively
I ran into this when trying to debug bug 407277. The output from trace-refcnt included the address of the leaked object in lowercase: 1476 @0x3f13ef90 (1 references; 0 from COMPtrs) but make-tree.pl gave me nothing for "--object 0x3f13ef90". It worked fine when I retried with "--object 0x3F13EF90". I only figured that out because find-leakers.pl outputs the address in uppercase. IMO, make-tree.pl should work given an address in either case.
This just requires changing this line: next LINE unless ($obj eq $::opt_object); to do a case-insensitive comparison. (Probably either call lc on both arguments -- maybe on $::opt_object once outside the loop -- or use the i parameter to a regexp match.)
I don't know perl, so can you do it? :)
[Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.1a2pre) Gecko/2008080121 Minefield/3.1a2pre] (home, debug default) (W2Ksp4) Uppercase the parameter value. Unrelated: *Move a line to optimize a loop a little. *Add/remove a few blank lines.
Assignee: nobody → sgautherie.bz
Status: NEW → ASSIGNED
Attachment #332291 - Flags: review?
Attachment #332291 - Flags: review? → review?(dbaron)
Severity: normal → minor
Component: XPCOM → Testing
OS: Mac OS X → All
QA Contact: xpcom → testing
Hardware: PC → All
Target Milestone: --- → mozilla1.9.1a2
Comment on attachment 332291 [details] [diff] [review] (Av1) <make-tree.pl> 1) don't reformat all the code 2) don't assume that the stuff in the log is one case or the other. It may vary between platforms. (However, find-leakers and make-tree are consistent.)
Attachment #332291 - Flags: review?(dbaron) → review-
[Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.9.1a2pre) Gecko/2008080121 Minefield/3.1a2pre] (home, debug default) (W2Ksp4) Av1, with comment 4 suggestion(s), plus: *Merge |$callGraphRoot| declar + init lines. *Add a few comments. *Remove unused |my ...|s. *Remove unreachable code. *Add forward declarations, to silence warnings. *And add a "missing" parameter value. *Indent one line.
Attachment #332308 - Flags: review?(dbaron)
Attachment #332291 - Attachment is obsolete: true
Comment on attachment 332308 [details] [diff] [review] (Av2) <make-tree.pl> Don't reformat all the code and make lots of arbitrary changes, especially given that this has no test suite.
Attachment #332308 - Flags: review?(dbaron) → review-
There's probably not a good component for bugs like these.
Component: Testing → General
Product: Core → Testing
QA Contact: testing → general
Target Milestone: mozilla1.9.1a2 → ---
You need to log in before you can comment on or make changes to this bug.