Bug 140976 assert condition off by one in ReportEngineService
The following assertion appears around line 516 in org.eclipse.birt.report.viewer\birt\WEB-INF\classes\org\eclipse\birt\report\services\ReportEngineService.java assert pageNumber > 0 && pageNumber < reportDocument.getPageCount( ); However, since page numbers start at 1 instead of 0, pageNumber could equal reportDocument.getPageCount(). So the assertion should be assert pageNumber > 0 && pageNumber <= reportDocument.getPageCount( );
viewer/org.eclipse.birt.report.viewer/birt/WEB-INF/classes/org/eclipse/birt/report/service/ReportEngineService.java
}
		else
		{
			renderContext.setBaseURL( this.contextPath
					+ IBirtConstants.SERVLET_PATH_FRAMESET );
		}
		renderContext.setSupportedImageFormats( svgFlag
				? "PNG;GIF;JPG;BMP;SVG" : "PNG;GIF;JPG;BMP" ); 
		return renderContext;
	}
	/**
	 * Create PDF render context.
	 * 
	 * @return
	 */
	private PDFRenderContext createPDFrenderContext( )
	{
		PDFRenderContext renderContext = new PDFRenderContext( );
		renderContext.setBaseURL( this.contextPath
				+ IBirtConstants.SERVLET_PATH_RUN );
		renderContext.setSupportedImageFormats( "PNG;GIF;JPG;BMP" ); 
		return renderContext;
	}
	/**
	 * Run and render a report,
	 * 
	 * @param runnable
	 * @param outputStream
	 * @param format
	 * @param locale