post installation script slightly broken

Bug #40469 reported by Phaedrus
8
Affects Status Importance Assigned to Milestone
kdebase (Ubuntu)
New
Medium
Unassigned

Bug Description

The postinst script for kcontrol 3.5.2-0ubuntu9 (latest in dapper repository) has a small bug. It has a bunch of lines in configure section to clean up some udev and hotplug stuff. It has the following lines:

        rmdir /etc/hotplug/usb 2>/dev/null
        rmdir /etc/hotplug 2>/dev/null

However, if these directories do not exist, the rmdir returns non-zero, and so does the script which means that apt thinks it failed. This can be easily remedied by changing the lines to:

        test -d /etc/hotplug/usb && rmdir /etc/hotplug/usb 2>/dev/null
        test -d /etc/hotplug && rmdir /etc/hotplug 2>/dev/null

This will still fail if these directories aren't empty, but I think that is the desired behaviour.

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.