diff options
author | Michael Biebl <biebl@debian.org> | 2009-11-05 03:11:30 +0100 |
---|---|---|
committer | Martin Pitt <martin.pitt@ubuntu.com> | 2009-11-05 15:08:19 +0100 |
commit | 6d8eed9015a6ca648fe1dad575621b6ea959a748 (patch) | |
tree | 4136dbc0c625d388949c6b3529020c2f35488c5f | |
parent | 3181fd30f1e1e6ef940e5586c6683a37cac3fb81 (diff) | |
download | hal-6d8eed9015a6ca648fe1dad575621b6ea959a748.tar.gz |
Support relative paths in umount.hal
http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=552139
-rw-r--r-- | tools/umount-hal.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/tools/umount-hal.c b/tools/umount-hal.c index 719943cc..81c3e081 100644 --- a/tools/umount-hal.c +++ b/tools/umount-hal.c @@ -31,12 +31,13 @@ #include <string.h> #include <libhal.h> #include <libhal-storage.h> +#include "../hald/util.h" int main (int argc, char *argv[]) { int ret; - char *device_file_or_mount_point; + char device_file_or_mount_point[HAL_PATH_MAX]; DBusError error; DBusConnection *con; LibHalContext *hal_ctx; @@ -58,7 +59,7 @@ main (int argc, char *argv[]) * first argument. TODO XXX FIXME: we ought to honor * umount(8) options like -v for verbose. */ - device_file_or_mount_point = argv[1]; + realpath(argv[1], device_file_or_mount_point); dbus_error_init (&error); con = dbus_bus_get (DBUS_BUS_SYSTEM, &error); |