Created
January 22, 2019 17:30
-
-
Save ChrisTheCoolHut/a6627981b08ae5ab47ebdff9d41e967f to your computer and use it in GitHub Desktop.
Syslog hook to print to STDOUT
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#define _GNU_SOURCE | |
#include <stdarg.h> | |
#include <stdio.h> | |
#include <dlfcn.h> | |
//dockcross-linux-armv5 bash -c '$CC verbal_syslog.c -fPIC -shared -ldl -o Verbal_syslog_static.so' | |
void syslog(int priority, const char* format, ...) | |
{ | |
va_list args; | |
va_start(args, format); | |
vprintf(format, args); | |
va_end(args); | |
printf("\n"); | |
fflush(stdout); | |
printf("\n") | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment