| .. | .. |
|---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-only |
|---|
| 1 | 2 | /* Copyright (C) by Paul Barton-Davis 1998-1999 |
|---|
| 2 | 3 | * |
|---|
| 3 | 4 | * Some portions of this file are taken from work that is |
|---|
| 4 | 5 | * copyright (C) by Hannu Savolainen 1993-1996 |
|---|
| 5 | | - * |
|---|
| 6 | | - * This program is distributed under the GNU GENERAL PUBLIC LICENSE (GPL) |
|---|
| 7 | | - * Version 2 (June 1991). See the "COPYING" file distributed with this software |
|---|
| 8 | | - * for more info. |
|---|
| 9 | 6 | */ |
|---|
| 10 | 7 | |
|---|
| 11 | 8 | /* |
|---|
| .. | .. |
|---|
| 791 | 788 | |
|---|
| 792 | 789 | dev->patch_status[header->number] |= WF_SLOT_FILLED; |
|---|
| 793 | 790 | |
|---|
| 794 | | - bptr = buf; |
|---|
| 795 | 791 | bptr = munge_int32 (header->number, buf, 2); |
|---|
| 796 | 792 | munge_buf ((unsigned char *)&header->hdr.p, bptr, WF_PATCH_BYTES); |
|---|
| 797 | 793 | |
|---|
| .. | .. |
|---|
| 1092 | 1088 | |
|---|
| 1093 | 1089 | if (dataptr < data_end) { |
|---|
| 1094 | 1090 | |
|---|
| 1095 | | - __get_user (sample_short, dataptr); |
|---|
| 1091 | + if (get_user(sample_short, dataptr)) |
|---|
| 1092 | + return -EFAULT; |
|---|
| 1096 | 1093 | dataptr += skip; |
|---|
| 1097 | 1094 | |
|---|
| 1098 | 1095 | if (data_is_unsigned) { /* GUS ? */ |
|---|