(reproduced with amd64 architecture, Gnome desktop) Problem occurs on 30% of tries 1. Open an existing file with Gedit 2. Modify something 3. Save (i.e. pressing Ctrl+S) Results: - Gedit breaks with message: GLib-GIO:ERROR:/build/glib2.0-B1uXKV/glib2.0-2.50.3/./gio/glocalfilemonitor.c:433:g_file_monitor_source_handle_event: code should not be reached - Text file is truncated to 0 bytes. No backup. Unrecoverable content.
Nautilus seems to break at same time. Circumstance can be that files to write has r+w permission for everybody, but aren't owned by current user (i.e.: root:users)
Worked fine, with no error, on Gedit version 3.10 The problem seems to be, although text file is readable and writable to owner & group & others, when saving from another user different to file owner.
Control: tags -1 moreinfo unreproducible Problem is not reproducible here I've created a file (userA:userA owned), then ran chmod 646 file.txt. Gedit will write to the file just fine. Please install dbgsym packages for gedit and create a proper backtrace.
Sorry, I forgot to test with and without setuid bit: $ id -un userA $ echo "Content text" > file.txt $ sudo chown userB file.txt $ sudo chmod u+s,g+rw file.txt $ nano file.txt # Modyfy and save: Fine. $ gedit file.txt # Modify and save: GLib-GIO:ERROR:/build/glib2.0-B1uXKV/glib2.0-2.50.3/./gio/glocalfilemonitor.c:433:g_file_monitor_source_handle_event: code should not be reached
Am 25.11.2017 um 12:17 schrieb Narcis Garcia: Given the special circumstances which are needed to trigger this issue, I'm downgrading the severity.
Have present that this bug does not make Gedit "completely unusable to everyone" (important), but "causes data loss" (grave), and it's a grave problem when someone uses Gedit to edit configuration files, source code files or script files: https://www.debian.org/Bugs/Developer#severities (Gedit is not used by most of people as a common word processor)
Am 25.11.2017 um 12:36 schrieb Narcis Garcia: I'm well aware of the different bug severities, thank you. That said, having the setuid bit set for a text file simply doesn't make any sense so I doubt anyone will be actually affected by this in practice as no such files should exist. The setuid bit only makes sense in the context of binaries which can be executed.