New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 792587 link

Starred by 1 user

Issue metadata

Status: Fixed
Owner:
Closed: Dec 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Chrome
Pri: 2
Type: Bug



Sign in to add a comment

suspend_stress_test fails with 'local: not in a function'

Project Member Reported by groeck@chromium.org, Dec 6 2017

Issue description

Running a recent M64 root file system, suspend_stress_test may fail to run with the following error.

/usr/bin/suspend_stress_test: 164: local: not in a function

Command line:

suspend_stress_test -c 5000 --wake_min=10 --wake_max=10 --memory_check --noerrors_fatal --nocrc_fatal -i "rtc_cmos"

The problem may be the result of a dash version update.

 
Status: Started (was: Assigned)
this script is large enough to warrant a proper main() func instead of an inline while loop.  plus it has the advantage of `local` working in that func scope.
Project Member

Comment 3 by bugdroid1@chromium.org, Dec 7 2017

The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/971cb6578b7836f6c2e9572e7c15b67008d0280b

commit 971cb6578b7836f6c2e9572e7c15b67008d0280b
Author: Guenter Roeck <groeck@chromium.org>
Date: Thu Dec 07 13:09:33 2017

power: suspend_stress_test: Drop local variable declaration

suspend_stress_test fails with the following error when running on
recent versions of dash.

/usr/bin/suspend_stress_test: 164: local: not in a function

The variable is only used in global context, so it is not necessary
to declare it as local variable.

BUG= chromium:792587 
TEST=Run 'suspend_stress_test -c 5000 --wake_min=10 --wake_max=10
	--memory_check --noerrors_fatal --nocrc_fatal -i "rtc_cmos"'

Change-Id: Ic55334c82119344a52a06fd2f4c109869f1bc4a7
Signed-off-by: Guenter Roeck <groeck@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/811831
Reviewed-by: Dan Erat <derat@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>

[modify] https://crrev.com/971cb6578b7836f6c2e9572e7c15b67008d0280b/power_manager/tools/suspend_stress_test

Labels: Merge-Request-64
Please add affected OSs.
Labels: OS-Chrome
Labels: -Merge-Request-64 Merge-Approved-64
Approving merge to M64 Chrome OS.
Project Member

Comment 8 by bugdroid1@chromium.org, Dec 7 2017

Labels: merge-merged-release-R64-10176.B
The following revision refers to this bug:
  https://chromium.googlesource.com/chromiumos/platform2/+/053acf7f24bee4bbbf0049f13e0371adf608b4a1

commit 053acf7f24bee4bbbf0049f13e0371adf608b4a1
Author: Guenter Roeck <groeck@chromium.org>
Date: Thu Dec 07 20:44:25 2017

power: suspend_stress_test: Drop local variable declaration

suspend_stress_test fails with the following error when running on
recent versions of dash.

/usr/bin/suspend_stress_test: 164: local: not in a function

The variable is only used in global context, so it is not necessary
to declare it as local variable.

BUG= chromium:792587 
TEST=Run 'suspend_stress_test -c 5000 --wake_min=10 --wake_max=10
	--memory_check --noerrors_fatal --nocrc_fatal -i "rtc_cmos"'

Change-Id: Ic55334c82119344a52a06fd2f4c109869f1bc4a7
Signed-off-by: Guenter Roeck <groeck@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/811831
Reviewed-by: Dan Erat <derat@chromium.org>
Reviewed-by: Mike Frysinger <vapier@chromium.org>
(cherry picked from commit 971cb6578b7836f6c2e9572e7c15b67008d0280b)
Reviewed-on: https://chromium-review.googlesource.com/815136

[modify] https://crrev.com/053acf7f24bee4bbbf0049f13e0371adf608b4a1/power_manager/tools/suspend_stress_test

Project Member

Comment 9 by sheriffbot@chromium.org, Dec 11 2017

Cc: kbleicher@google.com
This issue has been approved for a merge. Please merge the fix to any appropriate branches as soon as possible!

If all merges have been completed, please remove any remaining Merge-Approved labels from this issue.

Thanks for your time! To disable nags, add the Disable-Nags label.

For more details visit https://www.chromium.org/issue-tracking/autotriage - Your friendly Sheriffbot
Labels: -Merge-Approved-64
Status: Fixed (was: Started)

Sign in to add a comment