Item2542: empty paths in configure result in "NOT SET"

Priority: Low
Current State: Closed
Released In: 1.0.10, 1.1.0
Target Release: patch
Applies To: Engine
Component: configure
Reported By: WillNorris
Waiting For: WillNorris
Last Change By: KennethLavrsen

In configure all defined empty strings '' are converted into 'NOT SET'

This is done here in: lib/TWiki/Configure/Checkers/
    # If we got this far without definitions for key variables, then
    # we need to default them. otherwise we get peppered with
    # 'uninitialised variable' alerts later.
    foreach my $var qw( DataDir DefaultUrlHost PubUrlPath
                        PubDir TemplateDir ScriptUrlPath LocalesDir ) {
        # NOT SET tells the checker to try and guess the value later on
        $TWiki::cfg{$var} ||= 'NOT SET';

To fix we should change the line to:
        $TWiki::cfg{$var} = 'NOT SET' unless defined $TWiki::cfg{$var};

This is a small change that will only affect those who use empty strings as part of their configuration.

My ScriptUrlPath is set to an empty string.

-- TWiki:Main/VernonLyon - 30 Dec 2009

Apparently I changed this from WaitingForRelease to Closed, which is obviously wrong...

-- PaulHarvey - 20 Apr 2010

ItemTemplate edit

Summary empty paths in configure result in "NOT SET"
ReportedBy WillNorris
Codebase 1.0.8, 1.0.7, 1.0.6, 1.0.5, 1.0.5 beta1, 1.0.4, 1.0.3, 1.0.2, 1.0.1, 1.0.0, 1.0.0 beta3, 1.0.0 beta2, 1.0.0 beta1, trunk
SVN Range
AppliesTo Engine
Component configure
Priority Low
CurrentState Closed
WaitingFor WillNorris
Checkins distro:9e859052aa32 distro:7f4500f50f4d
TargetRelease patch
ReleasedIn 1.0.10, 1.1.0
Topic revision: r6 - 08 Sep 2010, KennethLavrsen - This page was cached on 16 Jan 2020 - 12:37.

The copyright of the content on this website is held by the contributing authors, except where stated elsewhere. See Copyright Statement. Creative Commons License    Legal Imprint    Privacy Policy