Re: [PATCH] nautilus_file_get_gicon() shouldn't dereference NULL file



On Wed, 2008-02-27 at 17:48 +0100, Christian Neumair wrote:
> Am Mittwoch, den 27.02.2008, 16:10 +0100 schrieb Alexander Larsson:
> > On Wed, 2008-02-27 at 15:59 +0100, Christian Neumair wrote:
> > > Am Mittwoch, den 27.02.2008, 15:31 +0100 schrieb Alexander Larsson:
> > > > Did you actually verify this crash?
> > > > I'm not sure how file got NULL as it comes from a
> > > > nautilus_file_get(location) call. But i guess location could be NULL. 
> > > > 
> > > > Anyway, it should be safe to commit. But are we sure it fixes the bug?
> > > 
> > > You are right, I could not verify/reproduce this crash. I verified and
> > > agree that this should only happen in the location == NULL case.
> > > 
> > > In general, we're not very robust wrt broken user data ATM, missing
> > > glade files or " " (two spaces) lines in bookmark files cause asserts to
> > > fail. Also note that in Thread 1#1 of the BT, there is a line containing
> > > 
> > > "** Message: failed to load session
> > > from /home/ron/.nautilus/saved-session-X"
> > > 
> > > so the user's data might be somewhat broken.
> > 
> > In fact the original ubuntu bug verifies this. That is the content of
> > his .gtk-bookmarks file. We should probably avoid this crash earlier in
> > the code.
> 
> I see. I'm also attaching a patch that makes the bookmark code ignore
> lines beginning with ' '. Is it OK to commit this one as well?

Add a comment why this is done too. Otherwise it looks good.




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