ios - Used type 'va_list' (aka '__builtin_va_list') where arithmetic or pointer type is required -


i using sqlite database function insert row given .

    - (nsnumber *) insertrow:(nsdictionary *) record {         // nslog(@"%s", __function__);         int dictsize = [record count];          // used use c-arrays.         // nsmutable data used make arc-compatible         // dkeys unused, necessary because nsdictionary:getobjects:andkeys         // way ordered list of values dictionary         nsmutabledata * dkeys = [nsmutabledata datawithlength: sizeof(id) * dictsize];         // dvalues used create argument list bindsql         nsmutabledata * dvalues = [nsmutabledata datawithlength: sizeof(id) * dictsize];         [record getobjects:(__unsafe_unretained id *)dvalues.mutablebytes andkeys:(__unsafe_unretained id *)dkeys.mutablebytes];          // construct query         nsmutablearray * placeholdersarray = [nsmutablearray arraywithcapacity:dictsize];         (int = 0; < dictsize; i++)  // array of ? markers placeholders in query             [placeholdersarray addobject: @"?"];          nsstring * query = [nsstring stringwithformat:@"insert %@ (%@) values (%@)",                             tablename,                             [[record allkeys] componentsjoinedbystring:@","],                             [placeholdersarray componentsjoinedbystring:@","]]; 
       [self bindsql:[query utf8string] withvargs:(va_list)dvalues.mutablebytes]; 
        sqlite3_step(statement);         if(sqlite3_finalize(statement) == sqlite_ok) {             return [self lastinsertid];         } else {             nslog(@"doquery: sqlite3_finalize failed (%s)", sqlite3_errmsg(database));             return @0;         }     } 

in function insertrow there in "bwdb.m" file giving compile time error @ highlighted line in above function: semantic issue used type 'va_list' (aka '__builtin_va_list') arithmetic or pointer type required.how can remove error ? form this link can download sample code correction.

similar question @ link problem persist .used type va_list (aka_builtin_va_list) arithmetic or pointer type required in bwdb.m file


Comments

Popular posts from this blog

android - InAppBilling registering BroadcastReceiver in AndroidManifest -

python Tkinter Capturing keyboard events save as one single string -

sql server - Why does Linq-to-SQL add unnecessary COUNT()? -