GNOME Bugzilla – Bug 62147
crash on FTP timeout
Last modified: 2005-08-15 01:48:59 UTC
when having an FTP view open to my university, if the connection times out and then I attempt to continue the session, nautilus will crash. reproduction: 1) connect to ftp site 2) leave for however long it takes for site to time out 3) attempt to continue the session (eg refresh) setup: nautilus, librsvg, eel, gnome-vfs - CVS the rest - Debian Sid packages In the end I had serious trouble getting a trace on it. doesn't seem to reproduce as easy as it was initially. I got this sometime in this process of attempting to find a trace. there's a chance it may not be from the crash, and may have been from a crash produced from a call to quit. hope it helps regardless. trace: (gdb) bt
+ Trace 11429
This seems worth attending to for GNOME 2. It will be useful if you can try 1.0.5 as soon as it's out the door and let us know if this is still happening.
Will do for sure (test with 1.0.5). But seeing as it's due out soon and I'm using CVS of everything anyway, I can't see what difference that will make...
The crash is in gnome-vfs so I'm moving the bug there (but I'll keep the 2.0 milestone)
Chris, can you still reproduce this? if so, can you try adding #define FTP_RESPONSE_DEBUG 1 at ftp-method.c and send the output? Thanks.
Maybe what I got is related. When we get a "421 Timeout" we keep reading for a response. Something to do with GNOME_VFS_ERROR_CANCELLED. I will look into it. It will be great to know if the reporter can reproduce the crash (mine is hang) with gnome-vfs 2.4.0.
confirmed in nautilus, it gets 100% cpu usage because keeps reading in: read_response_line called from connection_create called from do_open_directory. the context is not cancelled, just doing that may help. I will check.
in gnome_vfs_socket_buffer_read there is code that reads: if (result == GNOME_VFS_ERROR_EOF) { result = GNOME_VFS_OK; } This doesn't look sane as the ftp method then keeps trying to read on a ftp timeout because the result is alway GNOME_VFS_OK. proposed patch :) - if (result == GNOME_VFS_ERROR_EOF) { - result = GNOME_VFS_OK; - } Adding the patch keyword.
I think that makes sense. But if you change that then read_response_line() in nntp-method.c and ftp-method.c has to be changed to not call g_warning on EOF.
Umh, I don't understand why. If we get an EOF before we complete reading the response, it is an error. While playing with this change, I never got the warning, since usually when you do some ftp operation connection_acquire tries a "PWD" command, and as it fails because the sockect is closed we never go to read_response_line, but create a new connection. So I think it is good to get the warning when you get an EOF in the middle of reading a response line. If you still want it as a cosmetic change, I will post a patch so that it gets tested in 2.5.x.
Alex, can you comment on my last post? Thanks.
I'm changing the priority to high due to the patch and upping the severity to critical due to this being a crasher.
Hi, I'm waiting on Alexander Larsson to comment: "I think that makes sense. But if you change that then read_response_line() in nntp-method.c and ftp-method.c has to be changed to not call g_warning on EOF." I think that the g_warning makes sense, since it is an EOF while reading a response line.
All right. I commited this.
*** Bug 89046 has been marked as a duplicate of this bug. ***