After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 487357 - gedit is polling ~/.recently-used.xbel thus waking up the CPU
gedit is polling ~/.recently-used.xbel thus waking up the CPU
Status: RESOLVED DUPLICATE of bug 487375
Product: gtk+
Classification: Platform
Component: Class: GtkRecent
2.12.x
Other All
: Normal minor
: ---
Assigned To: gtk-bugs
Emmanuele Bassi (:ebassi)
Depends on:
Blocks:
 
 
Reported: 2007-10-17 02:18 UTC by William Lovaton
Modified: 2007-10-18 15:18 UTC
See Also:
GNOME target: ---
GNOME version: 2.19/2.20



Description William Lovaton 2007-10-17 02:18:57 UTC
Please describe the problem:
According to powertop gedit is waking up the CPU every 5 seconds while doing completely nothing.

An "strace -tt -p <pid-of-gedit>" shows that it is stat64()ing the file .recently-used.xbel in the user's home directory:

[william@localhost ~]$ strace -tt -p 2410
Process 2410 attached - interrupt to quit
20:59:03.717296 gettimeofday({1192586343, 717811}, NULL) = 0
20:59:03.718018 read(3, 0x9b0ae58, 4096) = -1 EAGAIN (Resource temporarily unavailable)
20:59:03.718436 gettimeofday({1192586343, 718658}, NULL) = 0
20:59:03.718827 poll([{fd=4, events=POLLIN}, {fd=3, events=POLLIN}, {fd=8, events=POLLIN|POLLPRI}, {fd=11, events=POLLIN|POLLPRI}, {fd=12, events=POLLIN|POLLPRI}, {fd=13, events=POLLIN|POLLPRI}, {fd=14, events=POLLIN}, {fd=10, events=POLLIN|POLLPRI}], 8, 1620) = 0
20:59:05.339285 gettimeofday({1192586345, 339449}, NULL) = 0
20:59:05.339647 stat64("/home/william/.recently-used.xbel", {st_mode=S_IFREG|0664, st_size=18610, ...}) = 0
20:59:05.340276 read(3, 0x9b0ae58, 4096) = -1 EAGAIN (Resource temporarily unavailable)
20:59:05.340675 gettimeofday({1192586345, 340809}, NULL) = 0
20:59:05.341046 poll([{fd=4, events=POLLIN}, {fd=3, events=POLLIN}, {fd=8, events=POLLIN|POLLPRI}, {fd=11, events=POLLIN|POLLPRI}, {fd=12, events=POLLIN|POLLPRI}, {fd=13, events=POLLIN|POLLPRI}, {fd=14, events=POLLIN}, {fd=10, events=POLLIN|POLLPRI}], 8, 4998) = 0
20:59:10.339287 gettimeofday({1192586350, 339454}, NULL) = 0
20:59:10.339724 stat64("/home/william/.recently-used.xbel", {st_mode=S_IFREG|0664, st_size=18610, ...}) = 0
20:59:10.340291 read(3, 0x9b0ae58, 4096) = -1 EAGAIN (Resource temporarily unavailable)
20:59:10.340676 gettimeofday({1192586350, 340807}, NULL) = 0
20:59:10.341039 poll([{fd=4, events=POLLIN}, {fd=3, events=POLLIN}, {fd=8, events=POLLIN|POLLPRI}, {fd=11, events=POLLIN|POLLPRI}, {fd=12, events=POLLIN|POLLPRI}, {fd=13, events=POLLIN|POLLPRI}, {fd=14, events=POLLIN}, {fd=10, events=POLLIN|POLLPRI}], 8, 4998) = 0
20:59:15.339264 gettimeofday({1192586355, 339501}, NULL) = 0
20:59:15.339705 stat64("/home/william/.recently-used.xbel", {st_mode=S_IFREG|0664, st_size=18610, ...}) = 0
20:59:15.340276 read(3, 0x9b0ae58, 4096) = -1 EAGAIN (Resource temporarily unavailable)
20:59:15.340669 gettimeofday({1192586355, 340803}, NULL) = 0
20:59:15.341040 poll( <unfinished ...>
Process 2410 detached


Steps to reproduce:
Every time you start gedit while doing nothing and there is no even a file loaded into the app.

Actual results:
gedit wakes up the CPU every 5 seconds keeping the system from saving power

Expected results:
gedit should use a notification mechanism to know that the recent files thing have changed and update the GUI accordingly, this way it wouldn't wake up the CPU while the user is not using the app at all.

Does this happen every time?
yes

Other information:
This is on an updated Rawhide system (Fedora 8 Test 3), the relevant packages are:
gedit-2.20.1-1.fc8
gtk2-2.12.0-6.fc8
glib2-2.14.1-1.fc8
Comment 1 Paolo Borelli 2007-10-17 16:42:32 UTC
gedit just uses gtkrecent api. Moving to gtk.
Comment 2 William Lovaton 2007-10-18 15:18:57 UTC
Well, this bug is now being tracked in #487375 by Emmanuele Bassi

*** This bug has been marked as a duplicate of 487375 ***