diff options
author | Hans de Goede <[email protected]> | 2016-06-29 14:32:19 +0200 |
---|---|---|
committer | Hans de Goede <[email protected]> | 2016-07-02 12:21:28 +0200 |
commit | d7dfd4cb511b3190c74f5a03ca9bd8351ad6d062 (patch) | |
tree | eb7064b26efe463be934ac94ffdbd82efb68daf3 /src/gallium/drivers/nouveau | |
parent | 110ef733dcd3fd306c513a2546b6e0a7d3179263 (diff) |
nv30: Fix "array subscript is below array bounds" compiler warning
gcc6 does not like the trick where we point to one entry before the
array start and then start a while with a pre-increment.
Signed-off-by: Hans de Goede <[email protected]>
Reviewed-by: Ilia Mirkin <[email protected]>
Diffstat (limited to 'src/gallium/drivers/nouveau')
-rw-r--r-- | src/gallium/drivers/nouveau/nv30/nv30_transfer.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/gallium/drivers/nouveau/nv30/nv30_transfer.c b/src/gallium/drivers/nouveau/nv30/nv30_transfer.c index 9ecbcd1087a..5299b70d08d 100644 --- a/src/gallium/drivers/nouveau/nv30/nv30_transfer.c +++ b/src/gallium/drivers/nouveau/nv30/nv30_transfer.c @@ -663,8 +663,7 @@ nv30_transfer_rect(struct nv30_context *nv30, enum nv30_transfer_filter filter, {} }; - method = methods - 1; - while ((++method)->possible) { + for (method = methods; method->possible; method++) { if (method->possible(nv30, filter, src, dst)) { method->execute(nv30, filter, src, dst); return; |