Re: Folders become inaccessible after browsing remote locations like ftp, smb



On Tue, 2005-04-05 at 21:03 +0530, dinoop thomas wrote:
> Hi Alex,
> 
> Thanks for inputs.
> 
> > I don't think the bug is in nautilus_bookmark_connect_file(). Whats
> > really causing the loop is the nautilus_bookmark_connect_file() call in:
> > if (nautilus_file_is_gone (file)) {
> > /* The file we were monitoring has been deleted,
> > * or moved in a way that we didn't notice. Make * a spanking new 
> > NautilusFile object for this * location so if a new file appears in 
> > this place * we will notice.
> > */
> > nautilus_bookmark_disconnect_file (bookmark);
> > nautilus_bookmark_connect_file (bookmark);
> > should_emit_appearance_changed_signal = TRUE;
> > }
> >
> > Does removing that call fix the problem? Then we'll cut the loop, but
> > we'll still re-read the information the next time someone calls e.g.
> > nautilus_bookmark_get_icon()
> 
> No, it does not solve the issue. Its getting called from many other 
> functions.

What gets called from other functions? What causes the loop if that is
removed?

> I feel a better way to solve problem is to check whether the remote file 
> actually exists or not, in nautilus_bookmark_uri_known_not_to_exist(). 
> The current check is incomplete and fails for remote locations. For 
> local files, g_file_test() is called to check its existence, which works 
> fine; so problem is not seen for local files. I have uploaded a patch in 
> bugzilla bug#170761 which tries to take care of remote locations. But I 
> am using nautilus_file_get_existing to figure out if remote file 
> actually exists or not. I am not sure of any other way to know this.
> 
> http://bugzilla.gnome.org/show_bug.cgi?id=170761.
> 
> Kindly give your valuable suggestions.

You can't ever check whether remote locations are permanently gone,
since there might be temporary issues (network down, no network) that
causes it to seem gone when it is not.

Furthermore, we don't want to do blocking i/o, so even a non-working
check would be much more complicated than just a call. And, as I told
you in my last mail, the nautilus_file_get_existing call is totally
wrong here. It doesn't in any way test whether a file exists. 

=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
 Alexander Larsson                                            Red Hat, Inc 
                   alexl redhat com    alla lysator liu se 
He's a war-weary Amish werewolf from a doomed world. She's a tortured 
streetsmart queen of the dead living homeless in New York's sewers. They fight 
crime! 




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]