~zisis00/drizzle/ldap_policy

« back to all changes in this revision

Viewing changes to plugin/innobase/include/mem0mem.ic

  • Committer: Zisis Sialveras
  • Date: 2012-08-09 18:18:22 UTC
  • mfrom: (2553.1.25 workspace)
  • Revision ID: zisis00@gmail.com-20120809181822-9wobhdfdx411tu5w
Some changes in ldap_policy

Show diffs side-by-side

added added

removed removed

Lines of Context:
350
350
        ulint           n)      /*!< in: size of the topmost element */
351
351
{
352
352
        mem_block_t*    block;
353
 
        void*           buf;
 
353
        byte*           buf;
354
354
 
355
355
        ut_ad(mem_heap_check(heap));
356
356
 
357
357
        block = UT_LIST_GET_LAST(heap->base);
358
358
 
359
 
        buf = (byte*)block + mem_block_get_free(block) - MEM_SPACE_NEEDED(n);
 
359
        buf = (byte*) block + mem_block_get_free(block) - MEM_SPACE_NEEDED(n);
360
360
 
361
361
#ifdef UNIV_MEM_DEBUG
362
 
        ut_ad(mem_block_get_start(block) <=(ulint)((byte*)buf - (byte*)block));
 
362
        ut_ad(mem_block_get_start(block) <= (ulint) (buf - (byte*) block));
363
363
 
364
364
        /* In the debug version, advance buf to point at the storage which
365
365
        was given to the caller in the allocation*/
366
366
 
367
 
        buf = (byte*)buf + MEM_FIELD_HEADER_SIZE;
 
367
        buf += MEM_FIELD_HEADER_SIZE;
368
368
 
369
369
        /* Check that the field lengths agree */
370
 
        ut_ad(n == (ulint)mem_field_header_get_len(buf));
 
370
        ut_ad(n == mem_field_header_get_len(buf));
371
371
#endif
372
372
 
373
 
        return(buf);
 
373
        return((void*) buf);
374
374
}
375
375
 
376
376
/*****************************************************************//**