g_file_make_directory_with_parents() will fail for already
existing directories, unlike g_mkdir_with_parents(), so mention
this clearly in the docs.
https://bugzilla.gnome.org/show_bug.cgi?id=660791
_GNU_SOURCE must be defined before including any other (system)
header, so defining it in glib-unix.h (and hoping no one has included
anything else before that) is wrong. And the "#define _USE_GNU"
workaround for this problem in gnetworkingprivate.h is even wronger
(and still prone to failure anyway due to single-include guards).
Fix this by defining _GNU_SOURCE in config.h when building against
glibc. In theory this is bad because new releases of glibc may include
symbols that conflict with glib symbols, which could then cause
compile failures. However, most people only see new releases of glibc
when they upgrade their distro, at which point they also generally get
new releases of gcc, which have new warnings/errors to clean up
anyway.
https://bugzilla.gnome.org/show_bug.cgi?id=649201
Move all the annotations over from gobject-introspection.
They will not be used directly by the introspection scanner for now,
instead they will be extracted by a script and updated manually
until introspection is properly integrated into the glib build
The (linux specific) system call splice can be
used to transfer data between file descriptors
whitout copying them into user space.
See bug #604086 for additional details.
Note: Since we export types with Iface in the name rather than
Interface we have to use some typedefs to make this work. New
interfaces should probably use Interface as the public name.
For details, see bug 587482. The new api:
- Provide new _with_operation() variants of all unmount and eject methods
- Add GMountOperation::show-processes signal
- this can be used to show processes blocking an unmount operation
- Deprecate all unmount and eject methods
- Add g_drive_can_start_degraded() method
- this is to avoid auto-starting degraded drives
- Make g_drive_stop() resp. g_file_stop_mountable() take a GMountOperation
- these ops were recently added and not yet public API so it's fine
to change how they work
- Provide a way to poll mountable files, e.g. g_file_poll_mountable()
- Add some missing file attributes for mountable files
- G_FILE_ATTRIBUTE_MOUNTABLE_UNIX_DEVICE_FILE
- needed for the GDU Nautilus extensions to format a volume
- G_FILE_ATTRIBUTE_MOUNTABLE_CAN_START_DEGRADED:
- mimics g_drive_can_start_degraded()
- G_FILE_ATTRIBUTE_MOUNTABLE_CAN_POLL:
- mimics g_drive_can_poll_for_media()
- G_FILE_ATTRIBUTE_MOUNTABLE_IS_MEDIA_CHECK_AUTOMATIC
- mimics g_drive_is_media_check_automatic()
GFile allows for the possibility that external implementations may not
support thread-default contexts yet, via
g_file_supports_thread_contexts(). GVolumeMonitor is not yet
thread-default-context aware.
Add a test program to verify that basic gio async ops work correctly
in non-default contexts.
http://bugzilla.gnome.org/show_bug.cgi?id=579984
Add API for starting/stopping drives. This new API will enable
GVolumeMonitor and GVfs implementations to add support for the
following features
1. Powering down external hard disk enclosures / drives
2. Starting/stopping multi-disk devices (such as RAID/btrfs/ZFS)
3. Connecting/disconnecting iSCSI devices
4. Reacting to the user pressing e.g. the "remove drive" button on
a IBM/Lenovo Ultrabay: http://www.thinkwiki.org/wiki/Ultrabay
See the bug for the corresponding GVfs and Nautilus changes.
The default implementation of g_file_copy() checked the size of the file
to copy to give useful progress updates unconditionally. This can cause
long delays on 1-connection FTP servers while it tries to open a second
connection before it returns EBUSY. This patch makes this query only
happen when we actually send progress updates.
2009-02-19 Alexander Larsson <alexl@redhat.com>
Bug 549298 – impossible to copy files with p (pipe) flag
* gfile.c:
(file_copy_fallback):
Error out if the source file is a special file
svn path=/trunk/; revision=7885
2009-02-18 Alexander Larsson <alexl@redhat.com>
Bug 560564 – Replacing a symlink with its linked file truncates the original file
* gioenums.h:
Add G_FILE_CREATE_REPLACE_DESTINATION
* glocalfileoutputstream.c:
(handle_overwrite_open):
(_g_local_file_output_stream_replace):
Handle G_FILE_CREATE_REPLACE_DESTINATION when overwriting files.
* gfile.c:
(file_copy_fallback):
Pass G_FILE_CREATE_REPLACE_DESTINATION to g_file_replace when copying
with overwrite.
svn path=/trunk/; revision=7880
2008-12-09 Alexander Larsson <alexl@redhat.com>
Bug 515777 - incorrect date&time on copy
* glocalfile.c:
(g_local_file_class_init):
Copy mtime by default
* gfile.c:
Change docs about G_FILE_COPY_ALL_METADATA to not mention
mtime as an example.
svn path=/trunk/; revision=7738
* gdesktopappinfo.c (get_all_desktop_entries_for_mime_type): add a
cast to stop a gcc warning
* gfile.c (g_file_copy_attributes): add parens to stop a gcc
warning
svn path=/trunk/; revision=7550
2008-08-09 Loïc Minier <lool@dooz.org>
Bug 535124 – umask 002 not being applied for new directories, new
files get the correct umask
* gfile.c (g_file_make_directory)
(g_file_make_directory_with_parents): Document ownership and
permissions of newly created directories as being the default
ones of the process.
svn path=/trunk/; revision=7330
2008-08-04 Matthias Clasen <mclasen@redhat.com>
Bug 546017 – Don't copy attributes when copying a symlink
* gfile.c (g_file_copy_attributes): Specify
G_FILE_QUERY_INFO_NOFOLLOW_SYMLINKS in the call to
g_file_set_attributes_from_info. Patch by Christian Kellner
svn path=/trunk/; revision=7294