[Pkg-iscsi-maintainers] Bug#688209: open-iscsi: invalid usage of "break" statement in init script
Michael Prokop
mika at debian.org
Thu Sep 20 10:32:57 UTC 2012
Package: open-iscsi
Version: 2.0.873-3
Severity: normal
The "break" statement in /etc/init.d/open-iscsi is misplaced
as it is used inside an 'if' statement inside a function:
| # Now let's mount
| log_daemon_msg "Mounting network filesystems"
| MOUNT_RESULT=1
| if mount -a -O _netdev >/dev/null 2>&1; then
| MOUNT_RESULT=0
| break
| fi
| log_end_msg $MOUNT_RESULT
Which results in:
| /etc/init.d/open-iscsi: line 129: break: only meaningful in a `for', `while', or `until' loop
Maybe it's worth using something like:
| # Now let's mount
| log_daemon_msg "Mounting network filesystems"
| mount -a -O _netdev >/dev/null 2>&1
| log_end_msg $?
instead?
regards,
-mika-
More information about the Pkg-iscsi-maintainers
mailing list