git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [egit PATCH] avoiding output in the error log

From
Robin Rosenberg <robin.rosenberg.lists@dewire.com>
Date
Aug 27, 2008, 21:50 UTC
Message-ID
<200808272350.56819.robin.rosenberg.lists@dewire.com>
In-Reply-To
<20080827203343.GN26523@spearce.org>
onsdagen den 27 augusti 2008 22.33.43 skrev Shawn O. Pearce:
Show 25 quoted lines
> Robin Rosenberg <robin.rosenberg.lists@dewire.com> wrote:
> > > @@ -197,8 +199,10 @@ synchronized (resources) {
> > >  	} // End ResCL
> > >  
> > >  	void clearDecorationState(IResource r) throws CoreException {
> > > -		r.setSessionProperty(GITFOLDERDIRTYSTATEPROPERTY, null);
> > > -		fireLabelProviderChanged(new LabelProviderChangedEvent(this, r));
> > > +		if (r.exists()) {
> > > +			r.setSessionProperty(GITFOLDERDIRTYSTATEPROPERTY, null);
> > > +			fireLabelProviderChanged(new LabelProviderChangedEvent(this, r));
> > > +		}
> > 
> > Shawn, you removed the test from the code in 4a230ea1. Perhaps you could care to
> > comment on this patch to restore the test, though slightly different.
> > 
> > 		if (r.isAccessible())
> > 			r.setSessionProperty(GITFOLDERDIRTYSTATEPROPERTY, null);
> 
> This may be a patch queue reordering bug.
> 
> If you look at 4a230ea1 I moved the isAccessible test higher up,
> such that we shouldn't enter into clearDecorationState unless the
> resource is accessible.  But there may currently be two code paths
> that enter this method, and a patch I did not yet submit had removed
> the other code path.

Good. So then the question is whether we should use isAccessible() or exists()? Normally this makes no difference, but for a Project (at least) there is a difference. I project that exits is not accessible when closed.

-- robin
Previous: Shawn O. PearceNext: Shawn O. Pearce
Message 4 of 5 in “avoiding output in the error log”
  1. avoiding output in the error logrobert_no.spam_m@yahoo.fr, Aug 27, 2008
  2. Robin RosenbergAug 27, 2008
  3. Shawn O. PearceAug 27, 2008
  4. Robin RosenbergAug 27, 2008
  5. Shawn O. PearceAug 27, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.