1
0
Fork 0
forked from len0rd/rockbox

Android: Minor changes in ldebugf.

git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30304 a1c6a512-1295-4272-9138-f99709370657
This commit is contained in:
Thomas Martitz 2011-08-14 13:58:39 +00:00
parent 4ed1340a7c
commit c0a4c66f9d

View file

@ -26,6 +26,7 @@
#include <android/log.h>
#include <stdarg.h>
#include <stdio.h>
#include <string.h>
#define LOG_TAG "Rockbox"
@ -42,10 +43,10 @@ void debugf(const char *fmt, ...)
void ldebugf(const char* file, int line, const char *fmt, ...)
{
va_list ap;
char buf[1024];
char buf[strlen(fmt) + 8];
snprintf(buf, sizeof(buf), "%s:%d %s", file, line, fmt);
va_start(ap, fmt);
__android_log_vprint(ANDROID_LOG_DEBUG, LOG_TAG " L", buf, ap);
__android_log_vprint(ANDROID_LOG_DEBUG, LOG_TAG, buf, ap);
va_end(ap);
}