Bernhard Miklautz
57f952bbbc
wlog: fix android build
2015-11-09 19:37:02 +01:00
Bernhard Miklautz
07417599ce
wlog: rework, cleanup and stabilize API
...
* only expose necessary functions and types in header
* don't expose appender internals
* add generic function WLog_ConfigureAppender to have the possibility
to configure appender specific settings
* detect appender availability if WLog_SetLogAppenderType or
WLog_Appender_New return FALSE or NULL respectively the appender isn't
available or the initialization failed. This is very useful for the
use with optional appenders.
* add Free to the appender interface. At the time of the Free the
appender is known and available so it can be called directly (instead
of calling the right function according to the type)
* make all appender internal function static
* all appenders return the generic wLogAppender type now. Typecasts
are internally done where necessary this abstracts the appenders more
cleanly
2015-11-09 18:25:45 +01:00
David FORT
5fbf26acf2
Add an UDP appender to wLog
...
This appender allows to receive the logs over a network connection using UDP packets.
You can see the logs using a listening netcat, for example: nc -ul 127.0.0.1 20000.
2015-11-04 18:11:19 +01:00
David FORT
2a8de84342
Take in account @bmiklautz remarks
...
* I have added a function to set the journal identifier
* the appender name has been changed from SYSTEMD to JOURNALD
2015-11-01 21:34:03 +01:00
David FORT
9ea301983d
Adds a systemd journal appender
2015-10-30 14:50:14 +01:00
Bernhard Miklautz
a011719831
Merge pull request #2940 from hardening/syslog_appender
...
Add a wLog syslog appender
2015-10-29 18:44:14 +01:00
David FORT
8d2aadfccd
Fixed a warning
2015-10-29 18:33:42 +01:00
David FORT
c2a322f4d0
Support syslog type for the WLOG_APPENDER env var
2015-10-29 18:31:22 +01:00
Martin Fleisz
08cbcb3577
wlog: Fix variable definitions
2015-10-23 12:08:20 +02:00
Martin Haimberger
b2398b3a9a
wlog: fixed return values
...
wlog used to return an int but the only meaning
of the return value was:
* negative ... error
* 0 or positive ... success
but the positve returned value was 1 or some id of some
subsystem, nothing meaningful for the caller.
For a more meaningful returnvalue we now use BOOL.
If something goes wrong FALSE is returned.
2015-10-21 01:11:06 -07:00
David FORT
16d36e3083
A malloc() pass on WinPR
...
This patch treats remaining non-checked mallocs. And changes to calloc in places
where it makes sense
2015-06-22 19:10:00 +02:00
Norbert Federa
1eff1a345e
free can handle NULL perfectly fine
2015-05-11 09:07:39 +02:00
Bernhard Miklautz
850de59b55
winpr: add checks for *alloc
...
Add missing checks if memory allocation was successful. Also adapt
caller(s) when possible.
2015-04-08 11:34:37 +02:00
Bernhard Miklautz
5692117f8c
wlog: add missing check
...
Integrate pull request feedback
2015-03-31 15:20:10 +02:00
Armin Novak
71d4b81c6d
Removed scopes.
2015-03-31 15:18:46 +02:00
Armin Novak
b1edaf677b
Removed duplicated NULL pointer checks.
2015-03-31 15:18:46 +02:00
Armin Novak
d50ce6bd7a
Corrected end of string checks.
2015-03-31 15:18:46 +02:00
Armin Novak
b3ea02a777
Removed INVALID_HANDLE_VALUE from types not using it.
2015-03-31 15:18:45 +02:00
Bernhard Miklautz
1d7b3694a9
Integrate feedback from pull request ( #2492 )
...
* shell: add missing NULL checks
* thread: handle case where HAVE_EVENTFD_H isn't defined
* wlog: return NULL instead of 0
* wlog: use g_RootLog instead of WLog_GetRoot
otherwise a new root might be initialized on uninit
* indentation and style fixes
2015-03-25 17:38:21 +01:00
Bernhard Miklautz
3c7662517c
hardening
...
Start to add missing checks for:
* *alloc
* *_New
2015-03-25 17:38:21 +01:00
Marc-André Moreau
ee5a354328
freerdp: more valgrind fixes
2014-12-27 15:34:45 -05:00
Marc-André Moreau
6c2ebb2b58
channels: redirection valgrind fixes
2014-12-27 13:50:50 -05:00
Armin Novak
b920f9a081
Fixed null pointer dereference.
2014-11-17 00:50:15 +01:00
Armin Novak
54224d4155
Fixed memory leak.
2014-11-17 00:07:58 +01:00
Armin Novak
83f6b24b16
Fixed API nonnull warning.
2014-11-16 23:58:39 +01:00
Armin Novak
2e1c2555a2
Fixed typo.
2014-11-16 23:50:46 +01:00
Armin Novak
28220d5b9f
Fixed allocation size warning.
2014-11-16 23:41:28 +01:00
Armin Novak
b7304f16b8
Fixed memory leak.
2014-11-16 15:47:57 +01:00
Armin Novak
4004543a33
Default WLog_Level is now INFO.
2014-09-17 09:28:40 +02:00
Armin Novak
69c0aa4b22
Fixed missing log message formatting argument on android.
2014-09-16 10:14:18 +02:00
Armin Novak
b22b897389
Reformatted changed files.
2014-09-09 16:32:22 +02:00
Armin Novak
a738f3c6ce
Added stacktrace in case of log recursion.
2014-09-09 16:32:04 +02:00
Armin Novak
7e3a1b3073
Now using macro to generate module specific log tag.
2014-09-09 16:32:04 +02:00
Armin Novak
3e21e570b8
Added recursion detection to WLog.
...
Dump functions now expect TAG and level as arguments.
2014-09-09 16:31:46 +02:00
Armin Novak
c32c48fbb6
Added recursion guard to logging functions.
2014-09-09 16:30:52 +02:00
Emmanuel Ledoux
9217de3bb1
winpr-utils: WLog_PrintMessageVA, include stdarg.h from wlog.h instead of wlog.c
2014-07-04 14:52:13 +02:00
Marc-André Moreau
c5a1a8ac27
libwinpr-sspi: fix native sspi build
2014-06-05 22:10:08 -04:00
Marc-André Moreau
e5a77c3105
libwinpr-utils: add support for fine grained wlog filter
2014-05-29 15:23:15 -04:00
Martin Haimberger
dd62e88098
fixed Wlog_Uninit to also free child logger
2014-04-11 02:23:16 -07:00
Marc-André Moreau
9668549fa4
Merge pull request #24 from MartinHaimberger/wlogimprovment
...
improved WLog
2014-02-12 06:54:20 -05:00
Marc-André Moreau
cdcd290c44
wfreerdp: fix most build warnings
2014-02-10 22:12:13 -05:00
Martin Haimberger
65d7e17d4c
improved WLog
...
childlogger use per default now a WLOG_LEVEL_INHERIT level
so the loglevel is taken from the first parent which has another level set.
2014-01-15 05:52:48 -08:00
Martin Haimberger
ad7be5a4ee
improved wlog so new logger inhertit the loglevel
...
of the root logger
2013-10-25 05:41:01 -07:00
Marc-André Moreau
a3f0f4c8dc
libfreerdp-core: started logging packets to pcap file
2013-10-08 23:43:57 -04:00
Marc-André Moreau
684db03578
libwinpr-utils: start implement wlog packet appender
2013-10-08 23:18:59 -04:00
Marc-André Moreau
07afc88878
libwinpr-utils: add some configurability to wlog with environment variables
2013-10-08 22:35:14 -04:00
Martin Haimberger
fea6d83367
fixed memory leak in wlog
2013-10-04 03:51:10 -07:00
Marc-André Moreau
aaeb4ea0b2
libwinpr-utils: add wlog support for image and binary data
2013-10-02 15:41:46 -04:00
Marc-André Moreau
0569de167d
libwinpr-utils: further split wlog framework into more source files, add some thread safety for write operations
2013-10-02 13:38:21 -04:00
Marc-André Moreau
3fb2724536
libwinpr-utils: fix default WLog behaviour
2013-10-01 20:45:20 -04:00