Changeset 13726

Show
Ignore:
Timestamp:
02/07/08 17:16:01 (5 months ago)
Author:
tamas
Message:

Ensure proper initialization of the fields expanded from the wildcard specification (#2206)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/gdal/ogr/ogrsf_frmts/generic/ogr_gensql.cpp

    r13721 r13726  
    167167        switch (psColDef->target_type) 
    168168        { 
     169            case SWQ_OTHER: 
     170              break; 
    169171            case SWQ_INTEGER: 
    170172              oFDefn.SetType( OFTInteger ); 
  • trunk/gdal/ogr/swq.c

    r13722 r13726  
    11921192        } 
    11931193 
    1194         /* read an extra token to check for brackets. */ 
    1195          
     1194        /* set up some default values. */ 
     1195        swq_cols[select_info->result_columns].field_precision = -1;  
     1196        swq_cols[select_info->result_columns].target_type = SWQ_OTHER; 
    11961197        select_info->result_columns++; 
    1197         swq_cols[select_info->result_columns-1].field_precision = -1;  
    1198         swq_cols[select_info->result_columns-1].target_type = SWQ_OTHER; 
    11991198 
    12001199        next_token = swq_token( input, &input, &next_is_literal ); 
     
    19221921            int compose = itable != -1; 
    19231922 
     1923            /* set up some default values. */ 
     1924            def->field_precision = -1;  
     1925            def->target_type = SWQ_OTHER; 
     1926 
    19241927            /* skip this field if it isn't in the target table.  */ 
    19251928            if( itable != -1 && field_list->table_ids != NULL