Changeset 59bc7c1 in rtems-libbsd


Ignore:
Timestamp:
Jun 19, 2015, 6:07:32 AM (4 years ago)
Author:
Chris Johns <chrisj@…>
Branches:
4.11, 5283630d2c9d40deb0183696d278e02644fe4326, freebsd-9.3, bc2ba9a9cdc7381c2a4f2ae6ee303be636f31368
Children:
54fb9f0
Parents:
c31922b
Message:

Remove #undefs and fix formatting.

Location:
rtemsbsd
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • rtemsbsd/include/machine/rtems-bsd-program.h

    rc31922b r59bc7c1  
    7373
    7474#ifndef RTEMS_BSD_PROGRAM_NO_EXIT_WRAP
    75   #undef exit
    7675  #define exit(code) rtems_bsd_program_exit(code)
    7776#endif
    7877
    7978#ifndef RTEMS_BSD_PROGRAM_NO_ERROR_WRAP
    80   #undef error
    8179  #define error(fmt, ...) rtems_bsd_program_error(fmt, ## __VA_ARGS__)
    8280#endif
    8381
    8482#ifndef RTEMS_BSD_PROGRAM_NO_GETPROGNAME_WRAP
    85   #undef getprogname
    8683  #define getprogname() rtems_bsd_program_get_name()
    8784#endif
    8885
    8986#ifndef RTEMS_BSD_PROGRAM_NO_PRINTF_WRAP
    90   #undef printf
    9187  #define printf(...) fprintf(stdout, __VA_ARGS__)
    9288#endif
  • rtemsbsd/rtems/rtems-bsd-program.c

    rc31922b r59bc7c1  
    5353#include <stdlib.h>
    5454
     55#undef printf
    5556#include <machine/rtems-bsd-program.h>
    5657
     
    122123rtems_bsd_program_error(const char *fmt, ...)
    123124{
    124   va_list list;
    125   va_start(list, fmt);
    126   vfprintf(stderr, fmt, list);
    127   fprintf(stderr, "\n");
    128   va_end(list);
    129   rtems_bsd_program_exit(1);
     125        va_list list;
     126        va_start(list, fmt);
     127        vfprintf(stderr, fmt, list);
     128        fprintf(stderr, "\n");
     129        va_end(list);
     130        rtems_bsd_program_exit(1);
    130131}
    131132
Note: See TracChangeset for help on using the changeset viewer.