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 332028 - sftp method needs to guard against broken pipes
sftp method needs to guard against broken pipes
Status: RESOLVED WONTFIX
Product: gnome-vfs
Classification: Deprecated
Component: Module: ssh/sftp
2.13.x
Other All
: High major
: ---
Assigned To: gnome-vfs maintainers
gnome-vfs maintainers
: 325554 349149 375569 (view as bug list)
Depends on:
Blocks:
 
 
Reported: 2006-02-21 13:09 UTC by Benjamin Berg
Modified: 2008-09-06 19:08 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Benjamin Berg 2006-02-21 13:09:37 UTC
If an ssh connection is killed because of some reason, gnome-vfs will still try to write/read to the ssh process. This of course does not work, which results in reading some uninitilized memory, and sometimes this causes a crash.

The sftp method should handle this case more gracefully. (ie. return an error that  the operation failed, and allow creation of a new connection)

Note that if this happens, the mainloop will also eat cpu time because the sftp method does not want to be notified of the G_IO_HUP (and it'll poll over and over).
Comment 1 Benjamin Berg 2006-02-21 13:10:56 UTC
The glib bug about the loop problem is bug 332030.
Comment 2 Christian Neumair 2006-02-21 16:14:31 UTC
Thanks for your bug report!
I experienced an ugly crasher today for that reason, will attach a backtrace later.
Comment 3 Christian Neumair 2006-02-23 15:34:38 UTC
*** Bug 325554 has been marked as a duplicate of this bug. ***
Comment 4 Christian Neumair 2006-02-23 15:35:13 UTC
Backtrace was generated from '/usr/bin/nautilus'

(no debugging symbols found)
Using host libthread_db library "/lib/tls/i686/cmov/libthread_db.so.1".
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
(no debugging symbols found)
[Thread debugging using libthread_db enabled]
[New Thread 922756800 (LWP 4850)]
[New Thread 907561904 (LWP 20912)]
[New Thread 914144176 (LWP 4852)]
0x376de283 in g_main_context_check () from /usr/lib/libglib-2.0.so.0

Thread 2 (Thread 907561904 (LWP 20912))

  • #0 __kernel_vsyscall
  • #1 __waitpid_nocancel
    from /lib/tls/i686/cmov/libpthread.so.0
  • #2 libgnomeui_module_info_get
    from /usr/lib/libgnomeui-2.so.0
  • #3 <signal handler called>
  • #4 g_logv
    from /usr/lib/libglib-2.0.so.0
  • #5 g_log
    from /usr/lib/libglib-2.0.so.0
  • #6 g_realloc
    from /usr/lib/libglib-2.0.so.0
  • #7 buffer_check_alloc
    at sftp-method.c line 243
  • #8 buffer_write
    at sftp-method.c line 286
  • #9 iobuf_send_read_request
    at sftp-method.c line 763
  • #10 do_read
    at sftp-method.c line 2016
  • #11 _gnome_vfs_handle_do_read
    at gnome-vfs-handle.c line 132
  • #12 gnome_vfs_read_cancellable
    at gnome-vfs-cancellable-ops.c line 134
  • #13 gnome_vfs_read
    at gnome-vfs-ops.c line 215
  • #14 copy_file
    at gnome-vfs-xfer.c line 1242
  • #15 copy_directory
    at gnome-vfs-xfer.c line 1641
  • #16 copy_items
    at gnome-vfs-xfer.c line 1813
  • #17 gnome_vfs_xfer_uri_internal
    at gnome-vfs-xfer.c line 2549
  • #18 _gnome_vfs_xfer_private
    at gnome-vfs-xfer.c line 2635
  • #19 _gnome_vfs_job_execute
    at gnome-vfs-job.c line 1563
  • #20 thread_entry_point
    at gnome-vfs-job-queue.c line 66
  • #21 g_thread_pool_free
    from /usr/lib/libglib-2.0.so.0
  • #22 g_static_private_free
    from /usr/lib/libglib-2.0.so.0
  • #23 start_thread
    from /lib/tls/i686/cmov/libpthread.so.0
  • #24 clone
    from /lib/tls/i686/cmov/libc.so.6

Comment 5 James "Doc" Livingston 2006-08-11 09:42:05 UTC
*** Bug 349149 has been marked as a duplicate of this bug. ***
Comment 6 James "Doc" Livingston 2006-08-11 09:46:13 UTC
Bug 349149 contains some analysis of the issue, as the reporter did some investigation and notes a few serious problems.
Comment 7 Jonathan Matthew 2006-11-15 21:24:37 UTC
*** Bug 375569 has been marked as a duplicate of this bug. ***
Comment 8 André Klapper 2007-02-14 17:21:01 UTC
also see bug 407298
Comment 9 André Klapper 2008-09-06 19:08:38 UTC
gnome-vfs has been deprecated and superseded by gio/gvfs since GNOME 2.22, hence mass-closing many of the gnome-vfs requests/bug reports. This means that gnome-vfs is NOT actively maintained anymore, however patches are still welcome.

If your reported issue is still valid for gio/gvfs, please feel free to file a bug report against glib/gio or gvfs.

@Bugzilla mail recipients: query for gnome-vfs-mass-close to get rid of these notification emails all together.


General further information: http://en.wikipedia.org/wiki/GVFS 
Reasons behind this decision are listed at http://www.mail-archive.com/gnome-vfs-list@gnome.org/msg00899.html