Fix rlimit on accounting file.
struct acct ac;
mm_segment_t fs;
unsigned long vsize;
+ unsigned long flim;
/*
* First check to see if there is enough free_space to continue
*/
fs = get_fs();
set_fs(KERNEL_DS);
+ /*
+ * Accounting records are not subject to resource limits.
+ */
+ flim = current->rlim[RLIMIT_FSIZE].rlim_cur;
+ current->rlim[RLIMIT_FSIZE].rlim_cur = RLIM_INFINITY;
file->f_op->write(file, (char *)&ac,
sizeof(struct acct), &file->f_pos);
+ current->rlim[RLIMIT_FSIZE].rlim_cur = flim;
set_fs(fs);
}