]> git.ipfire.org Git - thirdparty/dracut.git/commitdiff
profile.py: do not count negative timestamp differences
authorHarald Hoyer <harald@redhat.com>
Fri, 22 Jun 2012 13:14:27 +0000 (15:14 +0200)
committerHarald Hoyer <harald@redhat.com>
Fri, 29 Jun 2012 10:41:25 +0000 (12:41 +0200)
profile.py

index e1d0cabf8b21f574b0b266a8c3d7d087475bd868..7f98a136f4c2f60736733cb7ca8ea645b27221c0 100644 (file)
@@ -36,7 +36,8 @@ def gen_times(t):
         fx=float(x[0])
         if oldx:
             #print fx - float(oldx[0]), x[0], x[1], oldx[0], oldx[1]
-            yield (fx - float(oldx[0]), oldx[1])
+            if ((fx - float(oldx[0])) > 0):
+                    yield (fx - float(oldx[0]), oldx[1])
 
         oldx = x