From cec469059a7c734777a6bbab68d7c11c947b2d37 Mon Sep 17 00:00:00 2001 From: kichik Date: Fri, 9 Dec 2005 13:15:21 +0000 Subject: [PATCH] applied patch #1374675 - made error message for already defined label clearer git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@4439 212acab6-be3b-0410-9dea-997c60f758d6 --- Source/build.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/Source/build.cpp b/Source/build.cpp index f4b01c80..a07d0bf4 100644 --- a/Source/build.cpp +++ b/Source/build.cpp @@ -997,7 +997,13 @@ int CEXEBuild::add_label(const char *name) t->name_ptr==offs) { if (*name == '.') ERROR_MSG("Error: global label \"%s\" already declared\n",name); - else ERROR_MSG("Error: label \"%s\" already declared in section/function\n",name); + else + { + char *t = "section"; + if (build_cursection_isfunc) + t = "function"; + ERROR_MSG("Error: label \"%s\" already declared in %s\n",name,t); + } return PS_ERROR; } t++;