From 0fb4bc74b24ea96e80d4e27428b8c2451fbf0eb5 Mon Sep 17 00:00:00 2001 From: Niko Tyni Date: Sun, 4 Sep 2005 11:40:42 +0000 Subject: * lib/Smokeping.pm, CHANGES: + don't create directories in "datadir" when running as a CGI --- lib/Smokeping.pm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/Smokeping.pm') diff --git a/lib/Smokeping.pm b/lib/Smokeping.pm index a14699f..28923e7 100644 --- a/lib/Smokeping.pm +++ b/lib/Smokeping.pm @@ -363,7 +363,7 @@ sub init_target_tree ($$$$) { foreach my $prop (keys %{$tree}) { if (ref $tree->{$prop} eq 'HASH'){ - if (not -d $name) { + if (not -d $name and not $cgimode) { mkdir $name, 0755 or die "ERROR: mkdir $name: $!\n"; }; init_target_tree $cfg, $probes, $tree->{$prop}, "$name/$prop"; -- cgit v1.2.3-24-g4f1b