Index: trunk/Ohana/src/opihi/pantasks/CheckTasks.c
===================================================================
--- trunk/Ohana/src/opihi/pantasks/CheckTasks.c	(revision 4602)
+++ trunk/Ohana/src/opihi/pantasks/CheckTasks.c	(revision 4603)
@@ -17,4 +17,5 @@
     /* need to check if the current time is within valid/invalid periods */
     if (!CheckTimeRanges (task[0].ranges, task[0].Nranges)) continue;
+    if (task[0].Nmax && (task[0].Njobs >= task[0].Nmax)) continue;
 
     SetCurrentTask (task[0].name);
