]> source.dussan.org Git - jgit.git/commit
Strip leading slashes in RepositoryFilter 66/4666/1
authorShawn O. Pearce <spearce@spearce.org>
Tue, 22 Nov 2011 23:18:32 +0000 (15:18 -0800)
committerShawn O. Pearce <spearce@spearce.org>
Tue, 22 Nov 2011 23:19:02 +0000 (15:19 -0800)
commit9d311b333347d13ff2f9e0b7109e6b164a3643cc
treea2080486c295685c83970933b8a372fb2a54d84a
parent3ee3811afb4f1077c3c991a589e37725585c7e06
Strip leading slashes in RepositoryFilter

If removing the leading slash results in an empty string, return
with an HTTP 404 error before trying to use the RepositoryResolver.
Moving this into a loop ahead of the length check ensures there is
no empty string passed into the resolver.

Change-Id: I80e5b7cf25ae9f2164b5c396a29773e5c7d7286e
org.eclipse.jgit.http.server/src/org/eclipse/jgit/http/server/RepositoryFilter.java