- Timestamp:
- 04/22/96 16:50:17 (28 years ago)
- Branches:
- 4.10, 4.11, 4.8, 4.9, 5, master
- Children:
- 5a36154a
- Parents:
- 34f3d17
- Location:
- c/src/lib
- Files:
-
- 8 edited
Legend:
- Unmodified
- Added
- Removed
-
c/src/lib/include/rtems/libio.h
r34f3d17 r1f94ed6b 1 1 /* 2 * @(#)libio.h 1.1 - 95/06/023 *4 *5 2 * General purpose communication channel for RTEMS to allow UNIX/POSIX 6 3 * system call behavior on top of RTEMS IO devices. -
c/src/lib/libbsp/unix/posix/startup/bspstart.c
r34f3d17 r1f94ed6b 1 /*2 * @(#)bspstart.c 1.7 - 95/04/073 *4 */5 6 1 /* bsp_start() 7 2 * … … 56 51 int rtems_argc; 57 52 char **rtems_argv; 58 char **rtems_envp;59 53 60 54 /* … … 167 161 #ifdef RTEMS_DEBUG 168 162 rtems_debug_enable( RTEMS_DEBUG_ALL_MASK ); 163 #endif 164 165 /* 166 * Dump malloc stats on exit... 167 */ 168 #if defined(RTEMS_DEBUG) 169 atexit(malloc_dump); 169 170 #endif 170 171 } … … 199 200 rtems_fatal_error_occurred( error_code | 'I' << 8 | 'O' ); 200 201 #endif 201 202 #if defined(MALLOC_STATS)203 atexit(malloc_dump);204 #endif205 206 202 } 207 203 -
c/src/lib/libbsp/unix/posix/startup/rtems-ctor.cc
r34f3d17 r1f94ed6b 1 //2 // @(#)rtems-ctor.cc 1.6 - 95/04/253 //4 5 1 /* 6 2 * rtems-ctor.cc … … 91 87 rtems_argc = argc; 92 88 rtems_argv = argv; 93 rtems_envp = environp;94 89 95 90 if ((argc > 0) && argv && argv[0]) -
c/src/lib/libbsp/unix/posix/startup/setvec.c
r34f3d17 r1f94ed6b 32 32 ) 33 33 { 34 rtems_isr_entry rtems_isr_ptr ;34 rtems_isr_entry rtems_isr_ptr = 0; 35 35 proc_ptr raw_isr_ptr; 36 36 -
c/src/lib/libc/libio.c
r34f3d17 r1f94ed6b 1 1 /* 2 * @(#)libio.c 1.1 - 95/06/023 *4 *5 2 * Provide UNIX/POSIX-like io system calls for RTEMS using the 6 3 * RTEMS IO manager -
c/src/lib/libc/libio.h
r34f3d17 r1f94ed6b 1 1 /* 2 * @(#)libio.h 1.1 - 95/06/023 *4 *5 2 * General purpose communication channel for RTEMS to allow UNIX/POSIX 6 3 * system call behavior on top of RTEMS IO devices. -
c/src/lib/libc/malloc.c
r34f3d17 r1f94ed6b 26 26 #include <errno.h> 27 27 #include <string.h> 28 #include <unistd.h> /* sbrk(2) */ 28 29 29 30 rtems_id RTEMS_Malloc_Heap; … … 32 33 #ifdef RTEMS_DEBUG 33 34 #define MALLOC_STATS 35 #define MALLOC_DIRTY 34 36 #endif 35 37 … … 203 205 } 204 206 #endif 205 207 208 #ifdef MALLOC_DIRTY 209 (void) memset(return_this, 0xCF, size); 210 #endif 211 206 212 return return_this; 207 213 } … … 221 227 if ( cptr ) 222 228 memset( cptr, '\0', length ); 229 230 MSBUMP(malloc_calls, -1); /* subtract off the malloc */ 223 231 224 232 return cptr; -
c/src/lib/libc/newlibc.c
r34f3d17 r1f94ed6b 1 /*2 * @(#)newlibc.c 1.9 - 95/05/163 *4 */5 6 1 #if defined(RTEMS_NEWLIB) 7 2 8 3 /* 9 * File: newlibc.c,v10 * Project: PixelFlow11 * Created: 94/12/712 * Revision: 1.213 * Last Mod: 1995/05/09 20:24:3714 *15 4 * COPYRIGHT (c) 1994 by Division Incorporated 16 5 * … … 48 37 #include <sys/reent.h> /* for extern of _REENT (aka _impure_ptr) */ 49 38 50 #ifdef RTEMS_UNIX 51 #include <stdio.h> /* for setvbuf() */ 39 /* 40 * NOTE: When using RTEMS fake stat, fstat, and isatty, all output 41 * is line buffered so this setvbuf is not necessary. This 42 * setvbuf insures that we can redirect the output of a test 43 * on the UNIX simulator and it is in the same order as for a 44 * real target. 45 * NOTE: 46 * There is some problem with doing this on the hpux version 47 * of the UNIX simulator (symptom is printf core dumps), so 48 * we just don't for now. 49 * Not sure if this is a problem with hpux, newlib, or something else. 50 */ 51 52 #if defined(RTEMS_UNIX) && !defined(hpux) 53 #define NEED_SETVBUF 54 #endif 55 56 #ifdef NEED_SETVBUF 57 #include <stdio.h> 52 58 #endif 53 59 … … 197 203 if (current_task == deleted_task) 198 204 { 199 205 ptr = _REENT; 200 206 } 201 207 else 202 208 { 203 209 ptr = (struct _reent *) MY_task_get_note(deleted_task, LIBC_NOTEPAD); 204 210 } 205 211 … … 207 213 if (ptr && ptr != &libc_global_reent) 208 214 { 209 _wrapup_reent(ptr); 210 _reclaim_reent(ptr); 215 _wrapup_reent(ptr); 216 _reclaim_reent(ptr); 217 free(ptr); 211 218 } 212 219 … … 219 226 if (current_task == deleted_task) 220 227 { 221 228 _REENT = 0; 222 229 } 223 230 }
Note: See TracChangeset
for help on using the changeset viewer.