소스 검색

ENH: Handle script mode

Andy Cedilnik 22 년 전
부모
커밋
9c744cfe35
1개의 변경된 파일10개의 추가작업 그리고 2개의 파일을 삭제
  1. 10 2
      Source/cmFileCommand.cxx

+ 10 - 2
Source/cmFileCommand.cxx

@@ -170,8 +170,16 @@ bool cmFileCommand::HandleGlobCommand(std::vector<std::string> 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
       {