[cmake-commits] martink committed cmAddLibraryCommand.cxx 1.26 1.27

cmake-commits at cmake.org cmake-commits at cmake.org
Thu Jan 4 16:03:44 EST 2007


Update of /cvsroot/CMake/CMake/Source
In directory public:/mounts/ram/cvs-serv18281

Modified Files:
	cmAddLibraryCommand.cxx 
Log Message:
BUG: fix for bad argument handling


Index: cmAddLibraryCommand.cxx
===================================================================
RCS file: /cvsroot/CMake/CMake/Source/cmAddLibraryCommand.cxx,v
retrieving revision 1.26
retrieving revision 1.27
diff -u -d -r1.26 -r1.27
--- cmAddLibraryCommand.cxx	2 Oct 2006 16:01:19 -0000	1.26
+++ cmAddLibraryCommand.cxx	4 Jan 2007 21:03:41 -0000	1.27
@@ -38,8 +38,8 @@
   
   // If the second argument is "SHARED" or "STATIC", then it controls
   // the type of library.  Otherwise, it is treated as a source or
-  // source list name.
-  if(s != args.end())
+  // source list name. There man be two keyword arguments, check for them
+  while ( s != args.end() )
     {
     std::string libType = *s;
     if(libType == "STATIC")
@@ -62,6 +62,10 @@
       ++s;
       in_all = false;
       }
+    else
+      {
+      break;
+      }
     }
 
   if (s == args.end())



More information about the Cmake-commits mailing list