From a515f039047d4fd27845e88d3a7ccc61c185fcbb Mon Sep 17 00:00:00 2001 From: Gerard Wagener Date: Mon, 18 Jan 2010 21:52:20 +0100 Subject: [PATCH] Include timestamp into the message generated by the kernel --- aha/ahalib.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/aha/ahalib.py b/aha/ahalib.py index fa42ac5be70..2b2b59dfec4 100644 --- a/aha/ahalib.py +++ b/aha/ahalib.py @@ -1,7 +1,6 @@ #Common functions shared between aha and aha-worker #FIXME Memory leak in process trees -> need to clean up them #triggered by the kernel -#TODO loader should include timestamp in the message hash from ctypes import * import os,sys,random,datetime,json,time, unittest @@ -14,6 +13,9 @@ class AHAActions: #Can trow IOError def load_file(self,filename): msg = {} + s = os.stat(filename) + ts = int(s[os.path.stat.ST_CTIME]) + msg['timestamp'] = ts fp = open(filename,'r') for i in fp.read().split('\n'): try: