summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--drv.c4
-rw-r--r--drv.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/drv.c b/drv.c
index 36d6601..ea3bd64 100644
--- a/drv.c
+++ b/drv.c
@@ -765,11 +765,11 @@ void drv_resolve_format_and_use_flags(struct driver *drv, uint32_t format, uint6
out_use_flags);
}
-void drv_log_prefix(enum drv_log_level level, const char *prefix, const char *file, int line,
+void drv_log_prefix(enum drv_log_level level, const char *prefix, const char *func, int line,
const char *format, ...)
{
char buf[50];
- snprintf(buf, sizeof(buf), "[%s:%s(%d)]", prefix, basename(file), line);
+ snprintf(buf, sizeof(buf), "[%s:%s(%d)]", prefix, func, line);
va_list args;
va_start(args, format);
diff --git a/drv.h b/drv.h
index 3dedfd1..b61aedf 100644
--- a/drv.h
+++ b/drv.h
@@ -240,7 +240,7 @@ enum drv_log_level {
#define _drv_log(level, format, ...) \
do { \
- drv_log_prefix(level, "minigbm", __FILE__, __LINE__, format, ##__VA_ARGS__); \
+ drv_log_prefix(level, "minigbm", __func__, __LINE__, format, ##__VA_ARGS__); \
} while (0)
#define drv_loge(format, ...) _drv_log(DRV_LOGE, format, ##__VA_ARGS__)