[Fdo-trac] [fdo-trac] #907: SQLite provider m_nTotalProps is not initialized when select aggregates
    FDO 
    trac_fdo at osgeo.org
       
    Mon May 11 02:57:46 PDT 2015
    
    
  
#907: SQLite provider m_nTotalProps is not initialized when select aggregates
-----------------------------+-----------------------------
 Reporter:  christinebao     |        Owner:  christine bao
     Type:  defect           |       Status:  new
 Priority:  major            |    Milestone:  4.1.0
Component:  SQLite Provider  |      Version:  4.0.0
 Severity:  3                |   Resolution:
 Keywords:                   |  External ID:  DE22147
-----------------------------+-----------------------------
Comment (by christinebao):
 This exception happen in
 {{{
 void SltReader::ValidateIndex(sqlite3_stmt *pStmt, int index)
 {
     if (index < 0 || index >= m_nTotalProps)
     {
                 wchar_t tmp[15];
                 swprintf(tmp, 15, L"%d", index);
         throw FdoCommandException::Create((std::wstring(L"Property index
 \'") + tmp + L"\' is out of bounds.").c_str());
     }
 }}}
 `m_nTotalProps` is a memory cache to indicate how many columns the table
 has. It is initialized in each constructor, but forget to initialize in
 one constructor `SltReader::SltReader(SltConnection* connection,
 FdoIdentifierCollection* props, FdoParameterValueCollection*  parmValues,
 const char* fcname, const char* sql)` in case `props->GetCount()` is 0.
--
Ticket URL: <http://trac.osgeo.org/fdo/ticket/907#comment:2>
FDO <http://fdo.osgeo.org/>
Feature Data Objects
    
    
More information about the fdo-trac
mailing list