patch-2.4.5 linux/drivers/acpi/driver.c
Next file: linux/drivers/atm/eni.c
Previous file: linux/drivers/acorn/block/mfmhd.c
Back to the patch index
Back to the overall index
- Lines: 12
- Date:
Tue May 22 09:38:51 2001
- Orig file:
v2.4.4/linux/drivers/acpi/driver.c
- Orig date:
Fri Feb 9 11:45:58 2001
diff -u --recursive --new-file v2.4.4/linux/drivers/acpi/driver.c linux/drivers/acpi/driver.c
@@ -311,8 +311,10 @@
size = buf.length - file->f_pos;
if (size > *len)
size = *len;
- if (copy_to_user(buffer, data, size))
+ if (copy_to_user(buffer, data, size)) {
+ kfree(buf.pointer);
return -EFAULT;
+ }
}
kfree(buf.pointer);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)