Closed Bug 404606 Opened 19 years ago Closed 19 years ago

make Bootstrap::Step::PatcherConfig work with newer versions of Config::General

Categories

(Release Engineering :: General, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED

People

(Reporter: bhearsum, Assigned: bhearsum)

Details

Attachments

(1 file)

The version of Config::General used on the 1.8 slave setup is old (2.27); it's save_file() method does not return any value. The latest version of Config::General has a save_file() that always returns nothing ('return;') (unless it croak()'s). These lines of BumpPatcherConfig() are choking on that: 290 if (! $patcherConfigObj->save_file($checkedOutPatcherConfig)) { 291 die("save_file() failed\n"); 292 } Removing the if() statement seems to have no ill effects. I've attached a patch that does this.
Attachment #289524 - Flags: review?(rhelmer)
Comment on attachment 289524 [details] [diff] [review] remove save_file() error checking Hm, this seems ok, but we lose the error checking (my kingdom for reasonable exception handling in perl!) Is there any way to check for save_file() failure in both cases? Maybe by wrapping it in an eval()?
Attachment #289524 - Flags: review?(rhelmer) → review+
TBH, there is no error checking done even in the old version. There's absolutely no return statements in the old version, but it does croak if there's a problem. I don't think there's any win by checking the return statement in _either_ version, since it's never returning anything else (croak bails out, it doesn't force a function to return, right?).
Looks like croak() ends up calling die(), so we're fine.
Checking in Step/PatcherConfig.pm; /cvsroot/mozilla/tools/release/Bootstrap/Step/PatcherConfig.pm,v <-- PatcherConfig.pm new revision: 1.9; previous revision: 1.8 done
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Product: mozilla.org → Release Engineering
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: