[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[minion-cvs] Fix spurious assert failure on systems with low time re...



Update of /home/minion/cvsroot/src/minion/lib/mixminion
In directory moria.mit.edu:/tmp/cvs-serv7381/lib/mixminion

Modified Files:
	ServerInfo.py 
Log Message:
Fix spurious assert failure on systems with low time resolution

Index: ServerInfo.py
===================================================================
RCS file: /home/minion/cvsroot/src/minion/lib/mixminion/ServerInfo.py,v
retrieving revision 1.68
retrieving revision 1.69
diff -u -d -r1.68 -r1.69
--- ServerInfo.py	8 Dec 2003 07:13:58 -0000	1.68
+++ ServerInfo.py	12 Dec 2003 22:56:16 -0000	1.69
@@ -462,14 +462,14 @@
     def isValidFrom(self, startAt, endAt):
         """Return true iff this ServerInfo is valid at all time from 'startAt'
            to 'endAt'."""
-        assert startAt < endAt
+        assert startAt <= endAt
         return (self['Server']['Valid-After'] <= startAt and
                 endAt <= self['Server']['Valid-Until'])
 
     def isValidAtPartOf(self, startAt, endAt):
         """Return true iff this ServerInfo is valid at some time between
            'startAt' and 'endAt'."""
-        assert startAt < endAt
+        assert startAt <= endAt
         va = self['Server']['Valid-After']
         vu = self['Server']['Valid-Until']
         return ((startAt <= va and va <= endAt) or