summaryrefslogtreecommitdiff
path: root/daemon/main.c
Commit message (Collapse)AuthorAgeFilesLines
* Fix string comparisonSergio Costas Rodriguez2023-02-061-1/+1
| | | | | | | | In several places, the code compares to strings by comparing their pointers instead of using g_strcmp0(). Although this seems to work, it is incorrect. This MR fixes it.
* daemon: Create socket dir from gvfsd daemonOndrej Holy2021-04-151-0/+6
| | | | | | | | | | | Recently, GVfs switched from abstract sockets to named sockets. The socket dir is currently created by the individual daemons immediately before starting DBus server. If gvfsd-admin is started at first, the socket dir is owned by root user and thus it isn't accesible for other daemons and clients. Let's create the socket dir early from the gvfsd daemon to ensure correct ownership. https://gitlab.gnome.org/GNOME/gvfs/-/issues/552
* fuse: Adapt gvfsd-fuse to use fuse 3.xXi Ruoyao2019-04-041-3/+1
| | | | | | | | | | Gvfsd-fuse required the old 2.x versions of fuse. Fuse developers encourage developers to transition to the actively developed libfuse 3.x. This change adapt gvfsd-fuse to build with fuse 3.x. Note that fuse is no longer compatible with fuse 2.x. It now requires fuse 3.0.0 or later to build. Closes: https://gitlab.gnome.org/GNOME/gvfs/issues/323
* Use Unicode in translatable stringsPiotr Drąg2016-10-031-2/+2
| | | | | | See https://developer.gnome.org/hig/stable/typography.html https://bugzilla.gnome.org/show_bug.cgi?id=772219
* daemon: Enable debugging for the main daemon by GVFS_DEBUGOndrej Holy2016-07-131-0/+3
| | | | | | | | This is currently more-or-less just a cosmetic issue, because there aren't any debug prints in the main daemon, and because other daemons are spawned with the same enviroment. However this fixes debugging for the proposed admin daemon, because GVFS_DEBUG environment variable is not passed in pkexec environment.
* fuse: Do not suppress gvfsd-fuse outputOndrej Holy2016-05-241-2/+1
| | | | | | Fuse daemon is spawned with G_SPAWN_STDOUT_TO_DEV_NULL and G_SPAWN_STDERR_TO_DEV_NULL, which suppress its output. Use G_SPAWN_LEAVE_DESCRIPTORS_OPEN instead to simplify debugging.
* daemon: Allow controlling debug output from main daemonRoss Lagerwall2016-01-181-0/+8
| | | | | | | | | | | | | | | | | | Allow controlling whether backends spawned from the main daemon start with debug output enabled by adding a --debug command-line parameter and responding to the SIGUSR2 signal. Note that sending SIGUSR2 to the main daemon does not affect any already spawned backends. E.g. to capture the login debugging from the sftp backend without having to restart the main daemon: $ pkill -x -USR2 gvfsd $ gvfs-mount sftp://... $ journalctl -n 40 If --debug is given on the command-line, debug output is enabled for spawned daemons by default. Sending SIGUSR2 will then turn it off. https://bugzilla.gnome.org/show_bug.cgi?id=740660
* daemon: Fix unused variable warningOndrej Holy2015-08-041-2/+2
| | | | | Unused variable 'no_fuse' warning is shown if fuse support is disabled. Declare the variable conditionally to avoid the warning.
* daemon: register mount tracker skeleton by bus_acquired_handlerOndrej Holy2015-02-021-9/+14
| | | | | | | | Mount tracker skeleton is registered by name_acquired_handler currently, however it is too late. Therefore e.g. mount operation could fail for the first time with the following error: No such interface `org.gtk.vfs.MountTracker' on object at path /org/gtk/vfs/mounttracker
* Report gvfs version when --version is usedRoss Lagerwall2014-04-111-0/+9
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=727132
* fuse: Use the big_writes option to speed up writesRoss Lagerwall2013-10-081-4/+6
| | | | | | | | Without the big_writes option, fuse uses a block size of 4096 bytes which results in poor write performance. So use the big_writes option to write blocks up to 64KiB in size. https://bugzilla.gnome.org/show_bug.cgi?id=652540
* Adds infrastructure for the backends to exit cleanlyTimothy Arceri2013-04-151-0/+10
| | | | https://bugzilla.gnome.org/show_bug.cgi?id=511802
* Remove calls to g_type_init(), bump GLib required versionColin Walters2012-10-301-1/+0
| | | | | | See http://git.gnome.org/browse/glib/commit/?id=2002479c02fa6e468fc3f67ddc663657a52ebde8 https://bugzilla.gnome.org/show_bug.cgi?id=687236
* gdbus: Remove debug printsTomas Bzatek2012-07-311-1/+0
|
* gdbus: Use g_clear_object() where appropriateTomas Bzatek2012-07-311-2/+1
|
* gdbus: Remove no longer valid commentTomas Bzatek2012-07-311-2/+0
|
* gdbus: Enable daemon finalizationTomas Bzatek2012-07-311-3/+1
| | | | | | The crasher may have been possibly fixed in bug 669211. It's hard to hit the code path as long as gvfsdaemon calls hard exit().
* gdbus: Tweak mount finalizationTomas Bzatek2012-07-311-1/+8
|
* gdbus: Core daemon and client portTomas Bzatek2012-07-311-46/+110
| | | | | | | | | | | Port of most of the gvfs core, few bits still missing. Lot of debug prints around, will be removed in further commits. Same amount of TODOs and FIXMEs. Notes: * kill serials? * get rid of mainloops where applicable (copy/move progress callback, enumerator) * fix keyring integration * use gdbus builtin fd passing within gvfsdaemon.c, kill the extra_fd stuff
* Rename gvfs-fuse-daemon to gvfsd-fuseTomas Bzatek2012-07-301-1/+1
| | | | | | ...to stay consistent with the rest of the daemons. https://bugzilla.gnome.org/show_bug.cgi?id=680819
* Update the Address of the FSFFelix Möller2012-07-301-2/+2
| | | | | | | | | | | | | | | Updating the address of the FSF. This has been done by: while read file; do sed -i 's:59 Temple Place:51 Franklin Street:' $file sed -i 's:Suite 330:Fifth Floor:' $file sed -i 's:02111-1307:02110-1301:' $file done https://bugzilla.gnome.org/show_bug.cgi?id=656598 Signed-off-by: Tomas Bzatek <tbzatek@redhat.com>
* Keep using ~/.gvfs as fallbackAlexander Larsson2012-03-151-1/+5
| | | | | | | | If runtime dir is not specifically set we don't fall back to ~/.cache/gvfs, as that unnecessarily invalidates all existing documentation and scripts using ~/.gvfs. However, if it is set, we still use it.
* Use user runtime dir for gvfs mountsWilliam Jon McCann2012-02-071-1/+1
| | | | | | https://bugzilla.gnome.org/show_bug.cgi?id=646391 Signed-off-by: Tomas Bzatek <tbzatek@redhat.com>
* The -f (foreground) option prevent libfuse to call daemon(). First, this is ↵Jean-Christian de Rivaz2012-01-101-3/+10
| | | | | | not required as g_spawn_async() already detach the process. Secondly, calling daemon() and then pthread_create() produce an undefined result accoring to Opengroup. On system with the uClibc library this will badly hang the process. Signed-off-by: Jean-Christian de Rivaz <jc@eclis.ch>
* Adapt to GLib 2.31 deprecations and thread API changesMatthias Clasen2011-10-211-2/+0
| | | | | | | GStaticMutex and GStaticRWLock have been replaced by GMutex and GRWLock, and g_thread_init() is no longer needed. https://bugzilla.gnome.org/show_bug.cgi?id=661148
* Ignore SIGPIPE signals to avoid process termination on cancelled transferTomas Bzatek2011-08-291-0/+4
| | | | | | | | That way we would be able to properly get EPIPE when trying to write to a socket or pipe whose far end has been closed. This happens e.g. on file copy cancellation. Glib does similar thing on GSocket initialization. https://bugzilla.gnome.org/show_bug.cgi?id=649041
* get rid of modelines The modelines were inconsistent and caused issuesBenjamin Otte2008-04-221-2/+0
| | | | | | | | | * */*.[ch]: get rid of modelines The modelines were inconsistent and caused issues when used in different editors. svn path=/trunk/; revision=1756
* Don't autostart fuse backend if the GVFS_DISABLE_FUSE env var is setAlexander Larsson2008-03-141-0/+4
| | | | | | | | | | | | 2008-03-14 Alexander Larsson <alexl@redhat.com> * daemon/main.c: Don't autostart fuse backend if the GVFS_DISABLE_FUSE env var is set svn path=/trunk/; revision=1656
* Fix memory leaks.Carlos Garcia Campos2008-03-041-0/+3
| | | | | | | | | | | 2008-03-04 Carlos Garcia Campos <carlosgc@gnome.org> * common/gmountspec.c: (g_mount_spec_copy): * daemon/gvfsdaemon.c: (g_vfs_daemon_initiate_mount): * daemon/main.c: (main): Fix memory leaks. svn path=/trunk/; revision=1519
* Code cleanup from Kjartan: Removes unused code/variables. Uses rightAlexander Larsson2008-02-191-5/+5
| | | | | | | | | | | | | | | 2008-02-19 Alexander Larsson <alexl@redhat.com> * lots of *.c files: Code cleanup from Kjartan: Removes unused code/variables. Uses right printf types Uses non-deprecated dbus calls. Removes spurious ; and , deleted extra checks for NULL for g_free svn path=/trunk/; revision=1302
* Include locate.h for setlocaleGVFS_0_1_5Alexander Larsson2008-01-281-0/+1
| | | | | | | | | | | | 2008-01-28 Alexander Larsson <alexl@redhat.com> * daemon/daemon-main.c: * daemon/main.c: Include locate.h for setlocale svn path=/trunk/; revision=1192
* Enable translations for daemons and some l10n fixes. Patch from LucaAlexander Larsson2008-01-281-2/+16
| | | | | | | | | | | | | 2008-01-28 Alexander Larsson <alexl@redhat.com> * daemon/Makefile.am: * daemon/daemon-main.c: * daemon/main.c: Enable translations for daemons and some l10n fixes. Patch from Luca Ferretti. svn path=/trunk/; revision=1186
* Update for releaseAlexander Larsson2008-01-211-1/+32
| | | | | | | | | | | | | | | | | | 2008-01-21 Alexander Larsson <alexl@redhat.com> * NEWS: Update for release * daemon/Makefile.am: * daemon/main.c: Autospawn fuse on daemon start. * daemon/mount.c: (read_mountable_config): Remove debug spew svn path=/trunk/; revision=1158
* Fix translated "".Alexander Larsson2007-12-201-1/+1
| | | | | | | | | | | | | | 2007-12-20 Alexander Larsson <alexl@redhat.com> * daemon/main.c: Fix translated "". * hal/ghaldrive.c: Encode +/- as utf8 c escapes svn path=/trunk/; revision=1060
* Add copyright information to source files.Christian Kellner2007-11-011-0/+22
| | | | | | | | | | | | 2007-11-01 Christian Kellner <gicmo@gnome.org> * client/*.[ch]: * common/*.[ch]: * daemon/*.[ch]: * test/*.[ch]: Add copyright information to source files. svn path=/trunk/; revision=1007
* Update to API changes in gio.Sebastian Dröge2007-10-021-1/+0
| | | | | | | | | | | | | | | * client/gdaemonfile.c: (g_daemon_file_append_to), (g_daemon_file_create), (g_daemon_file_replace): * test/benchmark-gvfs-big-files.c: (create_file): * test/benchmark-gvfs-small-files.c: (create_file): Update to API changes in gio. * daemon/gvfschannel.c: * daemon/gvfsreadchannel.c: * daemon/gvfswritechannel.c: * daemon/main.c: Drop unecessary includes. svn path=/trunk/; revision=966
* Move the mount tracker code into mount.c so we have all mount related things ↵Alexander Larsson2007-09-131-3/+0
| | | | | | | | in one placs Original git commit by Alexander Larsson <alexl@redhat.com> at 1178703402 +0200 svn path=/trunk/; revision=529
* Update gvfs mounting to the new APIsAlexander Larsson2007-09-131-2/+2
| | | | | | Original git commit by Alexander Larsson <alexl@redhat.com> at 1178632314 +0200 svn path=/trunk/; revision=525
* Initialize dbus thread support in daemonsAlexander Larsson2007-09-131-1/+3
| | | | | | Original git commit by Alexander Larsson <alex@greebo.(none)> at 1170944568 +0100 svn path=/trunk/; revision=306
* More work on mounting. Automount of smb now works (test).Alexander Larsson2007-09-131-0/+3
| | | | | | Original git commit by Alexander Larsson <alex@greebo.(none)> at 1170415025 +0100 svn path=/trunk/; revision=296
* Initial mount tracker code part 2Alexander Larsson2007-09-131-0/+3
| | | | | | Original git commit by Alexander Larsson <alex@greebo.(none)> at 1169741730 +0100 svn path=/trunk/; revision=266
* Initial work on the new way to track mountpoints.Alexander Larsson2007-09-131-34/+26
| | | | | | | | Daemon side only. Original git commit by Alexander Larsson <alex@greebo.(none)> at 1165492556 +0100 svn path=/trunk/; revision=219
* Allow multiple backend in one daemonAlexander Larsson2007-09-131-4/+4
| | | | | | Original git commit by Alexander Larsson <alex@greebo.(none)> at 1164972080 +0100 svn path=/trunk/; revision=207
* Rename GVfsDaemonBackend to GVfsBackendAlexander Larsson2007-09-131-4/+4
| | | | | | Original git commit by Alexander Larsson <alex@localhost.localdomain> at 1161855599 +0200 svn path=/trunk/; revision=129
* More work on daemon scheduling etcAlexander Larsson2007-09-131-1/+3
| | | | | | Original git commit by Alexander Larsson <alex@localhost.localdomain> at 1161615951 +0200 svn path=/trunk/; revision=119
* More daemon & backend workAlexander Larsson2007-09-131-4/+9
| | | | | | Original git commit by Alexander Larsson <alex@localhost.localdomain> at 1161345154 +0200 svn path=/trunk/; revision=117
* Turn gvfsdaemon into a base classAlexander Larsson2007-09-131-0/+55
Original git commit by Alexander Larsson <alex@localhost.localdomain> at 1160421719 +0200 svn path=/trunk/; revision=105