Index: varstring.c =================================================================== --- varstring.c (revision 101) +++ varstring.c (working copy) @@ -772,17 +772,12 @@ break; } - Debug("Currently non existent variable $(%s)\n",currentitem); - - if (varstring == '}') - { - snprintf(name,CF_MAXVARSIZE,"${%s}",currentitem); - } - else - { - snprintf(name,CF_MAXVARSIZE,"$(%s)",currentitem); - } - strcat(buffer,name); + else /* GetMacroValue came back NULL, i.e. variable is undefined */ + { + Debug("Currently nonexistent variable $(%s)\n",currentitem); + FatalError("Attempt to use nonexistent variable"); + } + } sp += strlen(currentitem);