From 9c744cfe35060d5d389b5d37d8d48ecf68a3b93f Mon Sep 17 00:00:00 2001 From: Andy Cedilnik Date: Fri, 6 Feb 2004 15:18:55 -0500 Subject: [PATCH] ENH: Handle script mode --- Source/cmFileCommand.cxx | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/Source/cmFileCommand.cxx b/Source/cmFileCommand.cxx index ee537f398..5b55b23c6 100644 --- a/Source/cmFileCommand.cxx +++ b/Source/cmFileCommand.cxx @@ -170,8 +170,16 @@ bool cmFileCommand::HandleGlobCommand(std::vector const& args, if ( !cmsys::SystemTools::FileIsFullPath(i->c_str()) ) { std::string expr = m_Makefile->GetCurrentDirectory(); - expr += "/" + *i; - g.FindFiles(expr); + // Handle script mode + if ( expr.size() > 0 ) + { + expr += "/" + *i; + g.FindFiles(expr); + } + else + { + g.FindFiles(*i); + } } else {