From 359042081f7b97ae79dbfba21680e5e5f505c649 Mon Sep 17 00:00:00 2001 From: Drew DeVault Date: Wed, 2 Aug 2017 22:57:50 -0400 Subject: [PATCH] Fix #40 --- util/log.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/log.c b/util/log.c index 57cf24f7..78dc97f9 100644 --- a/util/log.c +++ b/util/log.c @@ -65,7 +65,7 @@ void _wlr_log(log_importance_t verbosity, const char *fmt, ...) { // '../backend/wayland/backend.c' will both be stripped to // 'backend/wayland/backend.c' const char *_strip_path(const char *filepath) { - static int srclen = strlen(WLR_SRC_DIR) + 1; + static int srclen = sizeof(WLR_SRC_DIR); if (strstr(filepath, WLR_SRC_DIR) == filepath) { filepath += srclen; } else if (*filepath == '.') {