patch-2.4.21 linux-2.4.21/net/8021q/vlanproc.c
Next file: linux-2.4.21/net/atm/atm_misc.c
Previous file: linux-2.4.21/net/8021q/vlan_dev.c
Back to the patch index
Back to the overall index
- Lines: 12
- Date:
2003-06-13 07:51:39.000000000 -0700
- Orig file:
linux-2.4.20/net/8021q/vlanproc.c
- Orig date:
2002-11-28 15:53:15.000000000 -0800
diff -urN linux-2.4.20/net/8021q/vlanproc.c linux-2.4.21/net/8021q/vlanproc.c
@@ -252,8 +252,10 @@
offs = file->f_pos;
if (offs < pos) {
len = min_t(int, pos - offs, count);
- if (copy_to_user(buf, (page + offs), len))
+ if (copy_to_user(buf, (page + offs), len)) {
+ kfree(page);
return -EFAULT;
+ }
file->f_pos += len;
} else {
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)