.. | .. |
---|
| 1 | +// SPDX-License-Identifier: GPL-2.0-or-later |
---|
1 | 2 | /* |
---|
2 | 3 | * Copyright (c) 1996 John Shifflett, GeoLog Consulting |
---|
3 | 4 | * john@geolog.com |
---|
4 | 5 | * jshiffle@netcom.com |
---|
5 | | - * |
---|
6 | | - * This program is free software; you can redistribute it and/or modify |
---|
7 | | - * it under the terms of the GNU General Public License as published by |
---|
8 | | - * the Free Software Foundation; either version 2, or (at your option) |
---|
9 | | - * any later version. |
---|
10 | | - * |
---|
11 | | - * This program is distributed in the hope that it will be useful, |
---|
12 | | - * but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
13 | | - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
14 | | - * GNU General Public License for more details. |
---|
15 | 6 | */ |
---|
16 | 7 | |
---|
17 | 8 | /* |
---|
.. | .. |
---|
744 | 735 | * source or destination for THIS transfer. |
---|
745 | 736 | */ |
---|
746 | 737 | if (!cmd->SCp.this_residual && cmd->SCp.buffers_residual) { |
---|
747 | | - ++cmd->SCp.buffer; |
---|
| 738 | + cmd->SCp.buffer = sg_next(cmd->SCp.buffer); |
---|
748 | 739 | --cmd->SCp.buffers_residual; |
---|
749 | 740 | cmd->SCp.this_residual = cmd->SCp.buffer->length; |
---|
750 | 741 | cmd->SCp.ptr = sg_virt(cmd->SCp.buffer); |
---|
.. | .. |
---|
1863 | 1854 | case 1: --x; |
---|
1864 | 1855 | break; |
---|
1865 | 1856 | case 2: ++x; |
---|
| 1857 | + fallthrough; |
---|
1866 | 1858 | case 3: ++x; |
---|
1867 | 1859 | } |
---|
1868 | 1860 | return x; |
---|