mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-28 18:51:56 -04:00
[PATCH] fix broken timestamps in AVC generated by kernel threads
Timestamp in audit_context is valid only if ->in_syscall is set. Signed-off-by: Al Viro <[email protected]>
This commit is contained in:
parent
7f0ed77d24
commit
48887e63d6
3 changed files with 7 additions and 6 deletions
|
|
@ -1121,9 +1121,7 @@ unsigned int audit_serial(void)
|
|||
static inline void audit_get_stamp(struct audit_context *ctx,
|
||||
struct timespec *t, unsigned int *serial)
|
||||
{
|
||||
if (ctx)
|
||||
auditsc_get_stamp(ctx, t, serial);
|
||||
else {
|
||||
if (!ctx || !auditsc_get_stamp(ctx, t, serial)) {
|
||||
*t = CURRENT_TIME;
|
||||
*serial = audit_serial();
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue