Check the return value of copyin.

Found by: Coverity Prevent (tm)
This commit is contained in:
scottl 2006-01-14 17:59:28 +00:00
parent 8378b93876
commit 2fb685782c

View File

@ -531,7 +531,8 @@ amr_linux_ioctl_int(struct cdev *dev, u_long cmd, caddr_t addr, int32_t flag,
ac = NULL;
ap = NULL;
copyin(addr, &ali, sizeof(ali));
if ((error = copyin(addr, &ali, sizeof(ali))) != 0)
return (error);
switch (ali.ui.fcs.opcode) {
case 0x82:
switch(ali.ui.fcs.subopcode) {