Changeset 214156d in rtems


Ignore:
Timestamp:
Jun 3, 2016, 12:54:05 PM (3 years ago)
Author:
Sebastian Huber <sebastian.huber@…>
Branches:
master
Children:
a2597f3
Parents:
3ad5f86
git-author:
Sebastian Huber <sebastian.huber@…> (06/03/16 12:54:05)
git-committer:
Sebastian Huber <sebastian.huber@…> (06/06/16 10:57:07)
Message:

mghttpd: Add RTEMS printer support

Location:
cpukit
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • cpukit/include/rtems/print.h

    r3ad5f86 r214156d  
    4040 * support.
    4141 */
    42 typedef struct {
     42typedef struct rtems_printer {
    4343  void                *context;
    4444  rtems_print_plugin_t printer;
    45 }rtems_printer;
     45} rtems_printer;
    4646
    4747/**
  • cpukit/mghttpd/mongoose.c

    r3ad5f86 r214156d  
    55205520  return ctx;
    55215521}
     5522#ifdef __rtems__
     5523#include <rtems/print.h>
     5524
     5525static int mg_printer_plugin(void *context, const char *fmt, va_list ap) {
     5526  return mg_vprintf(context, fmt, ap);
     5527}
     5528
     5529void rtems_print_printer_mg_printf(rtems_printer *printer, struct mg_connection *conn) {
     5530  printer->context = conn;
     5531  printer->printer = mg_printer_plugin;
     5532}
     5533#endif /* __rtems__ */
  • cpukit/mghttpd/mongoose.h

    r3ad5f86 r214156d  
    257257int mg_printf(struct mg_connection *,
    258258              PRINTF_FORMAT_STRING(const char *fmt), ...) PRINTF_ARGS(2, 3);
     259#ifdef __rtems__
     260struct rtems_printer;
     261void rtems_print_printer_mg_printf(struct rtems_printer *, struct mg_connection *);
     262#endif /* __rtems__ */
    259263
    260264
Note: See TracChangeset for help on using the changeset viewer.