Changeset 11d61759 in rtems for cpukit/libmisc/stackchk/check.c


Ignore:
Timestamp:
Sep 28, 2007, 3:03:48 PM (12 years ago)
Author:
Joel Sherrill <joel.sherrill@…>
Branches:
4.8
Children:
433c7cad
Parents:
e463596f
Message:

2007-09-28 Joel Sherrill <joel.sherrill@…>

  • libmisc/stackchk/check.c: Eliminate output with little information. Always print a blown message using the same routine. Now works with GNAT RTS -fstack-checking if you have patch for the RTEMS specific support in your GCC version.
File:
1 edited

Legend:

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

    re463596f r11d61759  
    6565  #if defined(__GNUC__)
    6666    if ( sp < the_stack->area ) {
    67       printk( "Stack Pointer Too Low!\n" );
    6867      return FALSE;
    6968    }
    7069    if ( sp > (the_stack->area + the_stack->size) ) {
    71       printk( "Stack Pointer Too High!\n" );
    7270      return FALSE;
    7371    }
     
    226224    if (rtems_configuration_get_user_multiprocessing_table()) {
    227225      printk(
    228         "; node=%d\n",
     226        "; node=%d",
    229227        rtems_configuration_get_user_multiprocessing_table()->node
    230228      );
    231229    }
    232   #else
    233       printk( "\n" );
    234230  #endif
    235231
    236232  printk(
    237     "  stack covers range 0x%p - 0x%p (%d bytes)\n",
     233    "\n  stack covers range 0x%p - 0x%p (%d bytes)\n",
    238234    stack->area,
    239235    stack->area + stack->size - 1,
     
    306302  }
    307303
    308   if ( !sp_ok || !pattern_ok ) {
    309     return TRUE;
    310   }
    311   return FALSE;
     304  /*
     305   * The Stack Pointer and the Pattern Area are OK so return FALSE.
     306   */
     307  if ( sp_ok && pattern_ok )
     308    return FALSE;
     309
     310  /*
     311   * Let's report as much as we can.
     312   */
     313  Stack_check_report_blown_task( _Thread_Executing, pattern_ok );
     314  return TRUE;
    312315}
    313316
Note: See TracChangeset for help on using the changeset viewer.