forked from Imagelibrary/rtems
2008-06-05 Joel Sherrill <joel.sherrill@OARcorp.com>
* posix/src/psignal.c: Do not allocate any memory for queued signals if the configuration parameter is 0. Before we would end up with an allocation of 0 which rounded up and wasted some memory when POSIX was configured.
This commit is contained in:
@@ -1,3 +1,10 @@
|
||||
2008-06-05 Joel Sherrill <joel.sherrill@OARcorp.com>
|
||||
|
||||
* posix/src/psignal.c: Do not allocate any memory for queued signals if
|
||||
the configuration parameter is 0. Before we would end up with an
|
||||
allocation of 0 which rounded up and wasted some memory when POSIX
|
||||
was configured.
|
||||
|
||||
2008-06-05 Joel Sherrill <joel.sherrill@OARcorp.com>
|
||||
|
||||
* libcsupport/src/newlibc_exit.c: Only run the fini section on exit if
|
||||
|
||||
@@ -205,12 +205,16 @@ void _POSIX_signals_Manager_Initialization(
|
||||
for ( signo=1 ; signo<= SIGRTMAX ; signo++ )
|
||||
_Chain_Initialize_empty( &_POSIX_signals_Siginfo[ signo ] );
|
||||
|
||||
_Chain_Initialize(
|
||||
&_POSIX_signals_Inactive_siginfo,
|
||||
_Workspace_Allocate_or_fatal_error(
|
||||
maximum_queued_signals * sizeof( POSIX_signals_Siginfo_node )
|
||||
),
|
||||
maximum_queued_signals,
|
||||
sizeof( POSIX_signals_Siginfo_node )
|
||||
);
|
||||
if ( maximum_queued_signals ) {
|
||||
_Chain_Initialize(
|
||||
&_POSIX_signals_Inactive_siginfo,
|
||||
_Workspace_Allocate_or_fatal_error(
|
||||
maximum_queued_signals * sizeof( POSIX_signals_Siginfo_node )
|
||||
),
|
||||
maximum_queued_signals,
|
||||
sizeof( POSIX_signals_Siginfo_node )
|
||||
);
|
||||
} else {
|
||||
_Chain_Initialize_empty( &_POSIX_signals_Inactive_siginfo );
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user