summaryrefslogtreecommitdiff
path: root/tools/hal-storage-shared.c
AgeCommit message (Collapse)AuthorFilesLines
2007-04-15remove use of "action parameters" now that they're going in PolicyKitDavid Zeuthen1-2/+0
2007-04-10fix build without policykit enabled/availableDanny Kukawka1-1/+3
Fixed build without policykit enabled/available. Added some ifdef's.
2007-04-09take advantage of new parameter API in PolKitActionDavid Zeuthen1-6/+8
These actions currently set parameters hal-storage-mount-[removable|fixed]: - fstype - mount-point - mount-options hal-lock - interface
2007-04-06port HAL over to use PolicyKit masterDavid Zeuthen1-13/+51
In the process, include hal-functions and make out shell-script based method handlers share that.
2007-03-27specify path to eject at build timeDavid Zeuthen1-7/+5
Based on a patch from Gabriel C <nix.or.die@googlemail.com>.
2007-03-25don't set INVOKED_BY_SYSTEMBUS_CONNECTION_NAME unless call is from busDavid Zeuthen1-1/+1
2007-03-25add interface locking and remove generic locking API committed yesterdayDavid Zeuthen1-0/+23
Now to write some docs how all this works...
2007-02-21refuse to eject if we can't open the device exclusivelyDavid Zeuthen1-0/+44
This is https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=207177 Btw, this code may be Linux specific? If so, please add guards for other OS's.
2007-02-17more ACL management work; now it's actually usuableDavid Zeuthen1-0/+1
2007-01-12changed error handling for hal-storage-shared.cDanny Kukawka1-5/+6
Changed error handling to differ between a real error while get volume.ignore and return true as value which should call permission_denied_volume_ignore().
2007-01-08call dbus_error_free() directly to avoid spew on stderrDavid Zeuthen1-1/+3
This patch is based on this discussion: Subject: [PATCH] Replace LIBHAL_FREE_DBUS_ERROR with dbus_error_free() in handle_unmount() From: Andrey Borzenkov <arvidjaar@mail.ru> When somebody calls Unmount on ignored media, hald crashes with: 19:00:32.166 [I] hald_dbus.c:2972: Refreshing mount state for /org/freedesktop/Hal/devices/volume_uuid_f340078d_4758_4d33_a4ac_a148c95c7558 since Unmount() completed 19:00:32.166 [I] hald_dbus.c:3027: failed with 'hal-storage-shared.c 285 : INFO: called LIBHAL_FREE_DBUS_ERROR but dbusError was not set.' 'org.freedesktop.Hal.Device.Volume.PermissionDenied' process 4822: arguments to dbus_message_new_error() were incorrect, assertion "_dbus_check_is_valid_error_name (error_name)" failed in file dbus-message.c line 1207. This is normally a bug in some application using the D-Bus library. The patch is using dbus_error_free() directly instead Signed-off-by: Andrey Borzenkov <arvidjaar@mail.ru>
2006-11-28add FreeBSD supportJoe Marcus Clarke1-3/+6
Add the necessary bits of code for FreeBSD.
2006-11-06solaris backendArtem Kachitchkine1-1/+1
Initial commit of the Solaris backend.
2006-09-23hald/linux/ids -> hald/ids and minor fixesArtem Kachitchkine1-2/+8
Let all backends share 'ids' code and some minor fixes.
2006-09-11make Mount() support option remountDavid Zeuthen1-2/+11
Now we also export 'exec' as a valid mount option. This way, for example, g-v-m can now remount a removable storage device with 'exec' to e.g. run an autolauncher. Had to put an #error into a Solaris specific code path, should be easy to fix, sorry Artem.
2006-09-02CloseTray() method (eject -t)Artem Kachitchkine1-0/+73
Add CloseTray() method to org.freedesktop.Hal.Device.Storage interface. Also add Eject() to that interface. Update HAL spec with definitions of the Storage and Volume interfaces.
2006-08-02 * configure.in: don't PKG_CHECK volume_id on SolarisArtem Kachitchkine1-1/+29
and check for asprintf() * hald/property.c: C99 compilers do not support anonymous unions * hald/util.h: redefine gcc macros if not using gcc * libhal/libhal.c: C99 compilers do not support anonymous unions * tools/hal-device: C99 compilers do not support anonymous unions, handle no-asprintf() case, use "a ? a : b" instead of "a ?: b" * tools/hal-storage-mount.c tools/hal-storage-shared.c tools/hal-system-power-pmu.c: added Solaris ifdefs
2006-07-29Merge branch 'master' of ssh://david@git.freedesktop.org/git/halDavid Zeuthen1-0/+1
2006-07-29introduce new option --disable-policy-kit and streamline the buildDavid Zeuthen1-1/+5
You explicitly have to pass --disable-policy-kit to configure and/or autogen.sh and if you do, a big fat warning will be displayed: NOTE: WARNING! WARNING! WARNING! PolicyKit is not enabled. HAL will allow any user to invoke any method. THIS IS A SECURITY RISK. Use this only if you really know what you are doing. Bugs, security issues and similar filed against HAL versions built without PolicyKit may be ignored by the HAL maintainers. Disable PolicyKit usage only if you really know what you are doing. This option might be removed in the future. Also clean up the build system by removing PACKAGE_CFLAGS and PACKAGE_LIBS. Binaries now have to specify exactly what libs they want.
2006-07-29Close memory leaks from not freed DBusError in tools src dirDanny Kukawka1-0/+1
Closed several memoryleaks related to not freed DBusError objects in *.c files in the tools dir by using LIBHAL_FREE_DBUS_ERROR macro. This include also a cleanup in hal-storage-mount.c and a fix for lshal to avoid start monitoring device list if we can't set the watch to all device properties.
2006-07-27git stuff, mount/umount/eject all in C, .hal-mtab usage, light_sensorDavid Zeuthen1-0/+481
and keyboard_backlight additions including example. Remove ChangeLog and add rules to Makefile.am (from cairo) to generate the ChangeLog file from git history. Add support for light_sensor and keyboard_backlight on my Macbook Pro. Add an examply python script to examples/ to show how it's done. Move Unmount, Eject and related stuff to C. Start using the file /media/.hal-mtab instead of .created-by-hal to specify if HAL created the mount point. Also list tons of metadata such as uid, session id (still unused). Fixes the bug where the unprivileged hald couldn't look into /media/foobar/ for the .created-by-hal file. So now doing 'umount /dev/sda1' on a volume mounted by HAL, makes hald remove the mount point as one would expect.