Changeset 8389628 in rtems for c/src/libmisc/stackchk


Ignore:
Timestamp:
Apr 22, 1996, 4:53:46 PM (25 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.10, 4.11, 4.8, 4.9, 5, master
Children:
d2d6467
Parents:
5a36154a
Message:

updates from Tony Bennett

File:
1 edited

Legend:

Unmodified
Added
Removed
  • c/src/libmisc/stackchk/check.c

    r5a36154a r8389628  
    2020
    2121#include <rtems.h>
     22
     23/*
     24 * HACK
     25 * the stack dump information should be printed by a "fatal" extension.
     26 * Fatal extensions only get called via rtems_fatal_error_occurred()
     27 * and not when rtems_shutdown_executive() is called.
     28 * I hope/think this is changing so that fatal extensions are renamed
     29 * to "shutdown" extensions.
     30 * When that happens, this #define should be deleted and all the code
     31 * it marks.
     32 */
     33#define DONT_USE_FATAL_EXTENSION
     34
    2235
    2336extern rtems_configuration_table BSP_Configuration;
     
    5063  Stack_check_Begin_extension,      /* task_begin   */
    5164  0,                                /* task_exitted */
     65#ifdef DONT_USE_FATAL_EXTENSION
     66  0,                                /* fatal        */
     67#else
    5268  Stack_check_Fatal_extension,      /* fatal        */
     69#endif
    5370};
    5471
     
    167184
    168185  Stack_check_Blown_task = 0;
    169 
    170 #ifdef STACK_CHECKER_REPORT_USAGE
    171   atexit( Stack_check_Dump_usage );
    172 #endif
    173186
    174187  /*
     
    218231  }
    219232
     233#ifdef DONT_USE_FATAL_EXTENSION
     234#ifdef RTEMS_DEBUG
     235    /*
     236     * this would normally be called by a fatal extension
     237     * handler, but we don't run fatal extensions unless
     238     * we fatal error.
     239     */
     240  atexit(Stack_check_Dump_usage);
     241#endif
     242#endif
     243
    220244  stack_check_initialized = 1;
    221245}
     
    432456 */
    433457
    434 void Stack_check_Fatal_extension( 
     458void Stack_check_Fatal_extension(
    435459    Internal_errors_Source  source,
    436460    boolean                 is_internal,
     
    438462)
    439463{
     464#ifndef DONT_USE_FATAL_EXTENSION
    440465    if (status == 0)
    441466        Stack_check_Dump_usage();
     467#endif
    442468}
    443469
Note: See TracChangeset for help on using the changeset viewer.