From e43a4769be3ad2cd88c7686d7436ce09d256918a Mon Sep 17 00:00:00 2001 From: John Johansen Date: Fri, 18 Apr 2008 21:01:10 +0000 Subject: [PATCH] retain the filename the profile was loaded from and use that when writting it back out --- utils/SubDomain.pm | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/utils/SubDomain.pm b/utils/SubDomain.pm index 63354ebb9..1d37d67e7 100755 --- a/utils/SubDomain.pm +++ b/utils/SubDomain.pm @@ -875,7 +875,11 @@ sub getprofilefilename ($) { my $profile = shift; my $filename = $profile; - $filename =~ s/\///; # strip leading / + if ($filename =~ /^\//) { + $filename =~ s/^\///; # strip leading / + } else { + $filename = "profile_$filename"; + } $filename =~ s/\//./g; # convert /'s to .'s return "$profiledir/$filename";