Ignore:
Timestamp:
Oct 1, 1998, 9:44:31 PM (21 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, master
Children:
082fc2d
Parents:
f0bca9fb
Message:

Patch from Ian Lance Taylor <ian@…>:

The reentrant versions of the malloc functions in

c/src/lib/libc/malloc.c

do not match the definitions in newlib. These will be used if you use
newlib routines such as fdopen. I believe this patch to malloc.c is
needed to provide the correct versions.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/exec/libcsupport/src/malloc.c

    rf0bca9fb r388be68  
    388388
    389389#ifdef RTEMS_NEWLIB
    390 void *malloc_r(
     390void *_malloc_r(
    391391  struct _reent *ignored,
    392392  size_t  size
     
    396396}
    397397
    398 void *calloc_r(
     398void *_calloc_r(
     399  struct _reent *ignored,
    399400  size_t nelem,
    400401  size_t elsize
     
    404405}
    405406
    406 void *realloc_r(
     407void *_realloc_r(
     408  struct _reent *ignored,
    407409  void *ptr,
    408410  size_t size
    409411)
    410412{
    411   return realloc_r( ptr, size );
    412 }
    413 
    414 void free_r(
     413  return realloc( ptr, size );
     414}
     415
     416void _free_r(
     417  struct _reent *ignored,
    415418  void *ptr
    416419)
Note: See TracChangeset for help on using the changeset viewer.