Fix RawParseUtils to match on the end of the buffer
commit925c8628a45d2e98470607c7f482a506438d8a62
authorShawn O. Pearce <spearce@spearce.org>
Thu, 15 Jan 2009 17:02:54 +0000 (15 09:02 -0800)
committerRobin Rosenberg <robin.rosenberg@dewire.com>
Thu, 15 Jan 2009 19:36:43 +0000 (15 20:36 +0100)
tree835950014676255085776fdd91f91ea63d3f83f1
parentaa1a979bf7b410421d3a1939d6c3bb973879cc12
Fix RawParseUtils to match on the end of the buffer

When we were matching exactly on the end of the buffer the match
method was failing because it incorrectly tested for >= on the
buffer length.  We only needed to test for > the buffer length.

JUnit tests for the match function are included to test for this
condition, and others.

Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com>
org.spearce.jgit.test/tst/org/spearce/jgit/util/RawParseUtils_MatchTest.java [new file with mode: 0644]
org.spearce.jgit/src/org/spearce/jgit/util/RawParseUtils.java