Bug 208419 NullPointerException at CubeResultSet close
engine/org.eclipse.birt.report.engine/src/org/eclipse/birt/report/engine/data/dte/DataInteractiveEngine.java
}
		dteSession = DataRequestSession.newSession( dteSessionContext );
		
		loadDteMetaInfo( reader );
		if ( writer != null && dos == null )
		{
			dos = new DataOutputStream(
					writer
							.createRandomAccessStream( ReportDocumentConstants.DATA_SNAP_META_STREAM ) );
			
			
			DteMetaInfoIOUtil.startMetaInfo( dos );
		}
	}
	
	
	/**
	 * save the metadata into the streams.
	 * 
	 * @param key
	 */
	private void storeDteMetaInfo( String pRsetId, String rowId,
			String queryId, String rsetId )
	{
		if ( dos != null )
		{
			try
			{
				
				if ( context.isExecutingMasterPage( ) )