From ed890a23a8317c806bd04d2b3fc468c6c0694b44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Marjam=C3=A4ki?= Date: Sun, 18 Aug 2013 09:01:03 +0200 Subject: [PATCH] Token::printOut(): don't write title if it's empty --- lib/token.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/token.cpp b/lib/token.cpp index 1d044fc57..3f5300074 100644 --- a/lib/token.cpp +++ b/lib/token.cpp @@ -969,14 +969,14 @@ void Token::createMutualLinks(Token *begin, Token *end) void Token::printOut(const char *title) const { - if (title) + if (title && title[0]) std::cout << "\n### " << title << " ###\n"; std::cout << stringifyList(true, true, true, true, true, 0, 0) << std::endl; } void Token::printOut(const char *title, const std::vector &fileNames) const { - if (title) + if (title && title[0]) std::cout << "\n### " << title << " ###\n"; std::cout << stringifyList(true, true, true, true, true, &fileNames, 0) << std::endl; }