mirror of https://github.com/apache/archiva.git
[MRM-353] fix for divide by zero error...
git-svn-id: https://svn.apache.org/repos/asf/maven/archiva/trunk@541112 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
503dc28855
commit
6473f82940
|
@ -2206,7 +2206,14 @@
|
||||||
}
|
}
|
||||||
|
|
||||||
buf.append( "\n Total File Count : " ).append( this.getTotalFileCount() );
|
buf.append( "\n Total File Count : " ).append( this.getTotalFileCount() );
|
||||||
long averageMsPerFile = ( this.getDuration() / this.getTotalFileCount() );
|
|
||||||
|
long averageMsPerFile = 0;
|
||||||
|
|
||||||
|
if ( this.totalFileCount != 0 )
|
||||||
|
{
|
||||||
|
averageMsPerFile = ( this.getDuration() / this.getTotalFileCount() );
|
||||||
|
}
|
||||||
|
|
||||||
buf.append( "\n Avg Time Per File : " );
|
buf.append( "\n Avg Time Per File : " );
|
||||||
buf.append( org.apache.maven.archiva.common.utils.DateUtil.getDuration( averageMsPerFile ) );
|
buf.append( org.apache.maven.archiva.common.utils.DateUtil.getDuration( averageMsPerFile ) );
|
||||||
buf.append( "\n______________________________________________________________" );
|
buf.append( "\n______________________________________________________________" );
|
||||||
|
|
Loading…
Reference in New Issue