source: rtems/testsuites/psxtests/psxkey01/init.c @ 9b4422a2

4.115
Last change on this file since 9b4422a2 was 9b4422a2, checked in by Joel Sherrill <joel.sherrill@…>, on 05/03/12 at 15:09:24

Remove All CVS Id Strings Possible Using a Script

Script does what is expected and tries to do it as
smartly as possible.

+ remove occurrences of two blank comment lines

next to each other after Id string line removed.

+ remove entire comment blocks which only exited to

contain CVS Ids

+ If the processing left a blank line at the top of

a file, it was removed.

  • Property mode set to 100644
File size: 1.2 KB
Line 
1/*
2 *  COPYRIGHT (c) 1989-1999.
3 *  On-Line Applications Research Corporation (OAR).
4 *
5 *  The license and distribution terms for this file may be
6 *  found in the file LICENSE in this distribution or at
7 *  http://www.rtems.com/license/LICENSE.
8 */
9
10#ifdef HAVE_CONFIG_H
11#include "config.h"
12#endif
13
14#define CONFIGURE_INIT
15#include "system.h"
16#include <errno.h>
17#include "tmacros.h"
18
19void Key_destructor(
20   void *key_data
21)
22{
23}
24
25
26void *POSIX_Init(
27  void *argument
28)
29{
30  int                    status;
31
32  puts( "\n\n*** POSIX KEY 01 TEST ***" );
33
34  /* set the time of day, and print our buffer in multiple ways */
35
36  set_time( TM_FRIDAY, TM_MAY, 24, 96, 11, 5, 0 );
37
38  /* get id of this thread */
39
40  Init_id = pthread_self();
41  printf( "Init's ID is 0x%08" PRIxpthread_t "\n", Init_id );
42
43  rtems_workspace_greedy_allocate( 0 );
44
45  puts("Init: pthread_key_create - ENOMEM (Workspace not available)");
46  empty_line();
47  status = pthread_key_create( &Key_id[0], Key_destructor );
48  fatal_directive_check_status_only( status, ENOMEM, "no workspace available" );
49
50  puts( "*** END OF POSIX KEY 01 TEST ***" );
51  rtems_test_exit( 0 );
52
53  return NULL; /* just so the compiler thinks we returned something */
54}
Note: See TracBrowser for help on using the repository browser.