bashism in Xen resource script

Bug #230653 reported by Nick Dyer
2
Affects Status Importance Assigned to Milestone
heartbeat (Ubuntu)
Fix Released
Medium
Luca Falavigna

Bug Description

Binary package hint: heartbeat

If I use heartbeat to monitor a Xen domain under hardy, then my log gets filled with messages like this:

May 15 11:22:00 sol lrmd: [5363]: info: RA output: (firewall:monitor:stderr) ==: unexpected operator

This is because on line 196 of the file

/usr/lib/ocf/resource.d/heartbeat/Xen

we have

  if [ "X${OCF_RESKEY_monitor_scripts}" == "X" ];then

which should be

  if [ "X${OCF_RESKEY_monitor_scripts}" = "X" ];then

This is a bashism. You can check for bashisms using the checkbashisms script shipped in the package devscripts

/usr/lib/ocf/resource.d/heartbeat$ checkbashisms Xen
possible bashism in Xen line 196 (should be 'b = a'):
  if [ "X${OCF_RESKEY_monitor_scripts}" == "X" ];then

The reason it is showing up in ubuntu is that /bin/sh is dash rather than bash.

Changed in heartbeat:
assignee: nobody → dktrkranz
importance: Undecided → Medium
status: New → In Progress
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package heartbeat - 2.1.3-6ubuntu1

---------------
heartbeat (2.1.3-6ubuntu1) intrepid; urgency=low

  * debian/patches/more_bashisms.patch:
    - Fix some bashisms (LP: #174182, #230653).
  * debian/control:
    - Update Maintainer field as per spec.

 -- Luca Falavigna <email address hidden> Thu, 19 Jun 2008 22:55:57 +0200

Changed in heartbeat:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.