Program: 76372
Project: 76372
Buggy source:
/** 
 * @see org.eclipse.birt.report.service.api.IViewerReportService#renderReportlet(java.lang.String,java.lang.String,org.eclipse.birt.report.service.api.InputOptions,java.util.List,java.io.OutputStream)
 */
public void renderReportlet(String docName,String objectId,InputOptions renderOptions,List activeIds,OutputStream out) throws ReportServiceException {
  IReportDocument doc=ReportEngineService.getInstance().openReportDocument(getReportDesignName(renderOptions),docName,getModuleOptions(renderOptions));
  HttpServletRequest request=(HttpServletRequest)renderOptions.getOption(InputOptions.OPT_REQUEST);
  Locale locale=(Locale)renderOptions.getOption(InputOptions.OPT_LOCALE);
  String format=(String)renderOptions.getOption(InputOptions.OPT_FORMAT);
  Boolean isMasterPageContent=(Boolean)renderOptions.getOption(InputOptions.OPT_IS_MASTER_PAGE_CONTENT);
  boolean isMasterPage=isMasterPageContent == null ? false : isMasterPageContent.booleanValue();
  Boolean svgFlag=(Boolean)renderOptions.getOption(InputOptions.OPT_IS_MASTER_PAGE_CONTENT);
  boolean isSvg=svgFlag == null ? false : svgFlag.booleanValue();
  Boolean isRtl=(Boolean)renderOptions.getOption(InputOptions.OPT_RTL);
  String servletPath=(String)renderOptions.getOption(InputOptions.OPT_SERVLET_PATH);
  try {
    ReportEngineService.getInstance().renderReportlet(out,request,doc,objectId,format,isMasterPage,isSvg,null,locale,isRtl.booleanValue(),servletPath);
  }
 catch (  RemoteException e) {
    throw new ReportServiceException(e.getLocalizedMessage(),e);
  }
 finally {
    if (doc != null)     doc.close();
  }
}

Fixed version (ground truth):
/** 
 * @see org.eclipse.birt.report.service.api.IViewerReportService#renderReportlet(java.lang.String,java.lang.String,org.eclipse.birt.report.service.api.InputOptions,java.util.List,java.io.OutputStream)
 */
public void renderReportlet(String docName,String objectId,InputOptions renderOptions,List activeIds,OutputStream out) throws ReportServiceException {
  IReportDocument doc=ReportEngineService.getInstance().openReportDocument(getReportDesignName(renderOptions),docName,getModuleOptions(renderOptions));
  HttpServletRequest request=(HttpServletRequest)renderOptions.getOption(InputOptions.OPT_REQUEST);
  Locale locale=(Locale)renderOptions.getOption(InputOptions.OPT_LOCALE);
  String format=(String)renderOptions.getOption(InputOptions.OPT_FORMAT);
  Boolean isMasterPageContent=(Boolean)renderOptions.getOption(InputOptions.OPT_IS_MASTER_PAGE_CONTENT);
  boolean isMasterPage=isMasterPageContent == null ? false : isMasterPageContent.booleanValue();
  Boolean svgFlag=(Boolean)renderOptions.getOption(InputOptions.OPT_IS_MASTER_PAGE_CONTENT);
  boolean isSvg=svgFlag == null ? false : svgFlag.booleanValue();
  Boolean isRtl=(Boolean)renderOptions.getOption(InputOptions.OPT_RTL);
  String servletPath=(String)renderOptions.getOption(InputOptions.OPT_SERVLET_PATH);
  try {
    ReportEngineService.getInstance().renderReportlet(out,request,doc,objectId,format,isMasterPage,isSvg,null,locale,isRtl.booleanValue(),servletPath);
  }
 catch (  RemoteException e) {
    throw new ReportServiceException(e.getLocalizedMessage(),e.getCause());
  }
 finally {
    if (doc != null)     doc.close();
  }
}