From 709b53bd4347ee0ba4925ae02a5f89ca15f380c8 Mon Sep 17 00:00:00 2001 From: Jerzi Kaminsky Date: Sun, 16 Apr 2017 12:07:43 +0300 Subject: Fix location reported by sway_assert --- common/log.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'common') diff --git a/common/log.c b/common/log.c index 23b756eb..8e5b71f9 100644 --- a/common/log.c +++ b/common/log.c @@ -142,14 +142,14 @@ void sway_log_errno(log_importance_t verbosity, char* format, ...) { } } -bool _sway_assert(bool condition, const char* format, ...) { +bool _sway_assert(bool condition, const char *filename, int line, const char* format, ...) { if (condition) { return true; } va_list args; va_start(args, format); - sway_vlog(L_ERROR, format, args); + _sway_vlog(filename, line, L_ERROR, format, args); va_end(args); #ifndef NDEBUG -- cgit v1.2.3