summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJames Moger <james.moger@gitblit.com>2011-07-12 20:27:56 -0400
committerJames Moger <james.moger@gitblit.com>2011-07-12 20:27:56 -0400
commit9cf48d26e7c95306844a2f8e640cd691de3be220 (patch)
tree0b2786c935e7d323f03fcebd049cf8b516f5a9d1
parent5c284113a1a458db0d3440de351034503b3d52b3 (diff)
downloadgitblit-9cf48d26e7c95306844a2f8e640cd691de3be220.tar.gz
gitblit-9cf48d26e7c95306844a2f8e640cd691de3be220.zip
Fix to build method.
-rw-r--r--build.xml3
-rw-r--r--src/com/gitblit/build/Build.java2
2 files changed, 3 insertions, 2 deletions
diff --git a/build.xml b/build.xml
index 954bc03f..ab794136 100644
--- a/build.xml
+++ b/build.xml
@@ -2,7 +2,8 @@
<project name="gitblit" default="compile" basedir=".">
<!-- Google Code upload task -->
- <taskdef classname="net.bluecow.googlecode.ant.GoogleCodeUploadTask" classpath="${basedir}/tools/ant-googlecode-0.0.3.jar" name="gcupload"/>
+ <taskdef classname="net.bluecow.googlecode.ant.GoogleCodeUploadTask"
+ classpath="${basedir}/tools/ant-googlecode-0.0.3.jar" name="gcupload"/>
<!-- Project Properties -->
<property name="project.jar" value="gitblit.jar" />
diff --git a/src/com/gitblit/build/Build.java b/src/com/gitblit/build/Build.java
index 998e7ba6..bd5e2f32 100644
--- a/src/com/gitblit/build/Build.java
+++ b/src/com/gitblit/build/Build.java
@@ -313,7 +313,7 @@ public class Build {
String anim = "==========";
int width = Math.round(anim.length() * progress);
System.out.print("\r[");
- System.out.print(anim.substring(0, width));
+ System.out.print(anim.substring(0, Math.min(width, anim.length())));
for (int i = 0; i < anim.length() - width; i++) {
System.out.print(' ');
}