Closed Bug 550704 Opened 10 years ago Closed 10 years ago

js/src/config/check-sync-dirs.py doesn't check file contents

Categories

(Firefox Build System :: General, defect, major)

defect
Not set
major

Tracking

(status1.9.2 .4-fixed, status1.9.1 .10-fixed)

RESOLVED FIXED
mozilla1.9.3a4
Tracking Status
status1.9.2 --- .4-fixed
status1.9.1 --- .10-fixed

People

(Reporter: glandium, Assigned: glandium)

Details

Attachments

(1 file)

From the python documentation:
filecmp.cmp(f1, f2[, shallow])
    Compare the files named f1 and f2, returning True if they seem equal, False otherwise.
    Unless shallow is given and is false, files with identical os.stat() signatures are taken to be equal.

In check-sync-dirs.py, shallow is not given, and if the compared files happen to have the same modification time and size, but not the same content, an error won't be emitted.

You'd think it's not important and highly improbable, but it just happened to me: I had significantly different config/rules.mk files, with same size and modification time (due to the fact the source was unpacked, then patched, so all the patches filed were modified within the same second), and the differences weren't (obviously) spotted.
Assignee: nobody → mh+mozilla
Attachment #430862 - Flags: review?(ted.mielczarek)
cjones hit this the other day in the opposite case, he had two config.mk files with the same contents, but different mtimes or something like that, and the script was complaining. That default behavior of filecmp is bizarre to me.
Attachment #430862 - Flags: review?(ted.mielczarek) → review+
Comment on attachment 430862 [details] [diff] [review]
Patch
[Checkin: Comment 3 & 5 & 6]


http://hg.mozilla.org/mozilla-central/rev/d9808811bb01
Attachment #430862 - Attachment description: Patch → Patch [Checkin: Comment 3]
Attachment #430862 - Flags: approval1.9.2.3?
Attachment #430862 - Flags: approval1.9.1.10?
Severity: normal → major
Status: NEW → RESOLVED
Closed: 10 years ago
Flags: in-testsuite-
Keywords: checkin-needed
Resolution: --- → FIXED
Target Milestone: --- → mozilla1.9.3a4
Comment on attachment 430862 [details] [diff] [review]
Patch
[Checkin: Comment 3 & 5 & 6]

Approved for 1.9.2.3 and 1.9.1.10, a=dveditz for release-drivers
Attachment #430862 - Flags: approval1.9.2.3?
Attachment #430862 - Flags: approval1.9.2.3+
Attachment #430862 - Flags: approval1.9.1.10?
Attachment #430862 - Flags: approval1.9.1.10+
Comment on attachment 430862 [details] [diff] [review]
Patch
[Checkin: Comment 3 & 5 & 6]


http://hg.mozilla.org/releases/mozilla-1.9.2/rev/52991d0b8a5b
Attachment #430862 - Attachment description: Patch [Checkin: Comment 3] → Patch [Checkin: Comment 3 & 5]
Comment on attachment 430862 [details] [diff] [review]
Patch
[Checkin: Comment 3 & 5 & 6]


http://hg.mozilla.org/releases/mozilla-1.9.1/rev/3a731a04de7c
Attachment #430862 - Attachment description: Patch [Checkin: Comment 3 & 5] → Patch [Checkin: Comment 3 & 5 & 6]
Product: Core → Firefox Build System
You need to log in before you can comment on or make changes to this bug.