rc = mdb_cursor_get( mcp, &key, &data, MDB_SET );
if ( !rc ) {
char *p2;
- ptr = data.mv_data + data.mv_size - sizeof( ID );
+ ptr = (char *)data.mv_data + data.mv_size - sizeof( ID );
memcpy( &nid, ptr, sizeof( ID ));
/* Get parent's node under grandparent */
d = data.mv_data;
op->o_tmpfree( p2, op->o_tmpmemctx );
if ( !rc ) {
/* Get parent's subtree count */
- ptr = data.mv_data + data.mv_size - sizeof( ID );
+ ptr = (char *)data.mv_data + data.mv_size - sizeof( ID );
memcpy( &subs, ptr, sizeof( ID ));
subs += nsubs;
p2 = op->o_tmpalloc( data.mv_size, op->o_tmpmemctx );
char *p2;
diskNode *d;
int rlen;
- ptr = data.mv_data + data.mv_size - sizeof( ID );
+ ptr = (char *)data.mv_data + data.mv_size - sizeof( ID );
memcpy( &nid, ptr, sizeof( ID ));
/* Get parent's node under grandparent */
d = data.mv_data;
op->o_tmpfree( p2, op->o_tmpmemctx );
if ( !rc ) {
/* Get parent's subtree count */
- ptr = data.mv_data + data.mv_size - sizeof( ID );
+ ptr = (char *)data.mv_data + data.mv_size - sizeof( ID );
memcpy( &subs, ptr, sizeof( ID ));
subs -= nsubs;
p2 = op->o_tmpalloc( data.mv_size, op->o_tmpmemctx );
*id = nid;
/* return subtree count if requested */
if ( !rc && nsubs ) {
- ptr = data.mv_data + data.mv_size - sizeof(ID);
+ ptr = (char *)data.mv_data + data.mv_size - sizeof(ID);
memcpy( nsubs, ptr, sizeof( ID ));
}
if ( !mc )
/* Get next sibling */
rc = mdb_cursor_get( isc->mc, &key, &data, MDB_NEXT_DUP );
if ( !rc ) {
- ptr = data.mv_data + data.mv_size - 2*sizeof(ID);
+ ptr = (char *)data.mv_data + data.mv_size - 2*sizeof(ID);
d = data.mv_data;
memcpy( &isc->id, ptr, sizeof(ID));
if (dkids > 1) {
rc = mdb_cursor_get(mc, &key, &data, MDB_NEXT_DUP);
down:
- ptr = data.mv_data + data.mv_size - sizeof(ID);
+ ptr = (unsigned char *)data.mv_data + data.mv_size - sizeof(ID);
memcpy(&id, ptr, sizeof(ID));
depth++;
memcpy(stack[depth].rdn, data.mv_data, data.mv_size);
goto leave;
}
data.mv_data = stack[depth].rdn;
- ptr = data.mv_data + data.mv_size;
+ ptr = (unsigned char *)data.mv_data + data.mv_size;
memcpy(ptr, &num[depth], sizeof(ID));
data.mv_size += sizeof(ID);
rc = mdb_cursor_del(mc, 0);