Hello. During compilation, the warning occurs sqlite3.c: In function 'deserializeGeometry': sqlite3.c:142353: warning: assignment from incompatible pointer type
for the sources of http://www.sqlite.org/2013/sqlite-autoconf-3080200.tar.gz with -DSQLITE_RTREE_INT_ONLY=1 and really 142314 /* 142315 ** This function is called to configure the RtreeConstraint object passed 142316 ** as the second argument for a MATCH constraint. The value passed as the 142317 ** first argument to this function is the right-hand operand to the MATCH 142318 ** operator. 142319 */ 142320 static int deserializeGeometry(sqlite3_value *pValue, RtreeConstraint *pCons){ 142321 RtreeMatchArg *p; 142322 sqlite3_rtree_geometry *pGeom; 142323 int nBlob; 142324 142325 /* Check that value is actually a blob. */ 142326 if( sqlite3_value_type(pValue)!=SQLITE_BLOB ) return SQLITE_ERROR; 142327 142328 /* Check that the blob is roughly the right size. */ 142329 nBlob = sqlite3_value_bytes(pValue); 142330 if( nBlob<(int)sizeof(RtreeMatchArg) 142331 || ((nBlob-sizeof(RtreeMatchArg))%sizeof(RtreeDValue))!=0 142332 ){ 142333 return SQLITE_ERROR; 142334 } 142335 142336 pGeom = (sqlite3_rtree_geometry *)sqlite3_malloc( 142337 sizeof(sqlite3_rtree_geometry) + nBlob 142338 ); 142339 if( !pGeom ) return SQLITE_NOMEM; 142340 memset(pGeom, 0, sizeof(sqlite3_rtree_geometry)); 142341 p = (RtreeMatchArg *)&pGeom[1]; 142342 142343 memcpy(p, sqlite3_value_blob(pValue), nBlob); 142344 if( p->magic!=RTREE_GEOMETRY_MAGIC 142345 || nBlob!=(int)(sizeof(RtreeMatchArg) + (p->nParam-1)*sizeof(RtreeDValue)) 142346 ){ 142347 sqlite3_free(pGeom); 142348 return SQLITE_ERROR; 142349 } 142350 142351 pGeom->pContext = p->pContext; 142352 pGeom->nParam = p->nParam; 142353 pGeom->aParam = p->aParam; | | | this is "double" or "sqlite3_int64" depending on the SQLITE_RTREE_INT_ONLY | this is always "double" 142354 142355 pCons->xGeom = p->xGeom; 142356 pCons->pGeom = pGeom; 142357 return SQLITE_OK; 142358 } 142359 7347 7348 /* 7349 ** A pointer to a structure of the following type is passed as the first 7350 ** argument to callbacks registered using rtree_geometry_callback(). 7351 */ 7352 struct sqlite3_rtree_geometry { 7353 void *pContext; /* Copy of pContext passed to s_r_g_c() */ 7354 int nParam; /* Size of array aParam[] */ 7355 double *aParam; /* Parameters passed to SQL geom function */ | maybe this field structure must be of type "RtreeDValue"? 7356 void *pUser; /* Callback implementation user data */ 7357 void (*xDelUser)(void *); /* Called by SQLite to clean up pUser */ 7358 }; 7359 Thank. _______________________________________________ sqlite-users mailing list sqlite-users@sqlite.org http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users