| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
Using GPrivate turned to be problematic wrt thread safety, better
to use the standard way of locks.
|
|
|
|
|
|
|
|
|
| |
Otherwise it would not be guaranteed that the messages got actually
sent if a program exits afterwards.
Synchronously flushing queued messages on a shared GDBusConnection
is quite risky as the queue could be rather long and we would block,
however the affected calls are not that common in normal use.
|
|
|
|
|
|
| |
Found by reading GDBus sources, things are easier when not specifying
a callback, e.g. g_dbus_connection_call() would set the
G_DBUS_MESSAGE_FLAGS_NO_REPLY_EXPECTED flag on the outgoing message.
|
|
|
|
|
|
|
|
|
| |
Since it didn't work and GVolumeMonitor implementations should not
be used from threads:
"GVolumeMonitor is not thread-default-context aware, and so
should not be used other than from the main thread, with
no thread-default-context active."
|
|
|
|
|
| |
The originally planned invocation in threads got never realized,
we're sufficiently async anyway.
|
|
|
|
|
| |
We don't need the result, let's make these calls async and retain
the old behaviour.
|
|
|
|
| |
...to reflect actual state of the shared proxy
|
|
|
|
|
|
| |
This helps to avoid constant metadata proxy creation for every call.
Instead, create it on first use and store it as thread-local data.
It gets unreff'ed on thread end automatically.
|
| |
|
| |
|
|
|
|
| |
And minimize roundtrips to the session d-bus daemon.
|
|
|
|
|
| |
Not needed really, leaving DEBUG_ENABLED define enabled for now, will
remove more debug prints later.
|
|
|
|
| |
Since they're misleading now with GDBus
|
| |
|
| |
|
|
|
|
|
| |
Bunch of cosmetic code-style changes, making our d-bus interface
conform to generally accepted rules.
|
|
|
|
|
|
| |
This would hopefully make autotools to compile generated sources in the
first place so others would be able to include them. Found by accident
and haven't been able to reproduce since.
|
|
|
|
| |
And ignore autogenerated related source files.
|
|
|
|
|
|
|
|
|
| |
Some TODOs:
* print better error messages when we can't own the dbus name
* remove dbus.h includes and CFLAGS once gvfsdaemonprotocol.h is ported
* "Get" method call unused?
|
| |
|
|
|
|
|
|
|
| |
... and don't scare users with correct informational messages.
One of owner_appeared of owner_vanished callbacks are guaranteed
to be called after name owner watching is set up and on normally
functional system the former is usually called.
|
|
|
|
|
|
|
|
|
|
|
| |
This typically happens when dbus eavesdrop is turned on and
we receive signals that don't belong to us. So simply silence
all warnings and ignore these events.
See https://bugs.freedesktop.org/show_bug.cgi?id=37890
Also, the hash table might not have been initialized yet,
added few tests.
|
|
|
|
|
|
|
|
| |
Use G_PROXY_VOLUME_MONITOR_DBUS_TIMEOUT (30 minutes) timeout where
applicable to match pre-gdbus volume monitor behavior.
Note that I chose to wrap locking in convenient functions to avoid
having the lock definition in a header file.
|
| |
|
|
|
|
|
|
| |
Per discussion with David it was suggested this is not so good idea
as long as most volume monitor operations are called async anyway and
we would have to hassle with GMainContext.
|
|
|
|
|
|
|
|
| |
Typically happens when receiving side is not aware of extra GError domains
registered on sending (server) side, such as GDU_ERROR.
While the receiving side will get different error (G_IO_ERROR_DBUS_ERROR)
it's not usually a problem as long as the error message is preserved.
|
|
|
|
|
|
|
|
|
| |
Few leftovers:
* Nuke the complicated is_supported machinery if possible
* Tweak timeouts for some operations
* Fix occasional GMountOperation lookup failures
|
|
|
|
|
| |
g_bus_watch_name() never returns zero so we can use it to distinguish
if watching has been started or not.
|
|
|
|
| |
specific owner
|
|
|
|
|
|
|
|
| |
There's no strong reason for having those as methods apart from precise
message targetting (TODO). This step will also significantly ease porting
of client side volume monitor.
This is a gvfs d-bus api break however.
|
| |
|
|
|
|
|
|
|
|
|
| |
Still few things to do:
* wrong error passing (G_IO_ERROR_FAILED_HANDLED getting ignored)
* add proper locking, review existing code to be thread-safe
* enabled debug prints by default for the moment
|
| |
|
| |
|
| |
|
|
|
|
|
|
| |
... instead of unmounting.
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
|
|
|
|
| |
Yes, can_eject can be TRUE even if the media is not removable.
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
|
|
|
|
|
| |
Like the rest of gvfs-mount(1), this is mostly useful for debugging.
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
|
|
|
|
|
|
| |
It may indeed take more than 25 seconds if there's a lot of data to
write. Related to https://bugzilla.redhat.com/show_bug.cgi?id=819492
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
|
|
|
|
|
| |
Same as http://cgit.freedesktop.org/udisks/commit/?id=d8fa361eec2706091e9d7f166f63bb5c0f663f4b
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
|
|
|
| |
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
|
|
|
| |
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
|
|
|
|
|
|
| |
We might bring this back in one shape or the other, but remove it for
now until I get a chance to talk to Kay and Lennart some more.
Signed-off-by: David Zeuthen <davidz@redhat.com>
|
| |
|
| |
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=578027
|
|
|
|
|
| |
g_clear_object expects the address of a pointer. A recent
change in its definition makes gcc complain about this.
|
| |
|
| |
|
| |
|