[Fix] Modifications to allow compilation for kernels from 2.6.18 (such as used in RH5 or CentOS5 distributions)

- Changing calls to ktime_get() by getnstimeofday() when compiling on older kernels.
- Disabling detection of connection closing for kernel prior to 2.6.22
- Adding missing imports.
- Purging the content of the flow hash map before releasing the memory.