[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 13/20] blockdev: Remove dead assignment
From: |
Laurent Vivier |
Subject: |
[PULL 13/20] blockdev: Remove dead assignment |
Date: |
Mon, 4 May 2020 13:57:51 +0200 |
From: Philippe Mathieu-Daudé <address@hidden>
Fix warning reported by Clang static code analyzer:
CC blockdev.o
blockdev.c:2744:5: warning: Value stored to 'ret' is never read
ret = blk_truncate(blk, size, false, PREALLOC_MODE_OFF, errp);
^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Reported-by: Clang Static Analyzer
Signed-off-by: Philippe Mathieu-Daudé <address@hidden>
Reviewed-by: Max Reitz <address@hidden>
Message-Id: <address@hidden>
[lv: fix conflict because of "Add flags to blk_truncate()"]
Signed-off-by: Laurent Vivier <address@hidden>
---
blockdev.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/blockdev.c b/blockdev.c
index dc1a0c7c2fd4..708d0c323fd2 100644
--- a/blockdev.c
+++ b/blockdev.c
@@ -2741,7 +2741,7 @@ void qmp_block_resize(bool has_device, const char *device,
}
bdrv_drained_begin(bs);
- ret = blk_truncate(blk, size, false, PREALLOC_MODE_OFF, 0, errp);
+ blk_truncate(blk, size, false, PREALLOC_MODE_OFF, 0, errp);
bdrv_drained_end(bs);
out:
--
2.26.2
- [PULL 00/20] Trivial branch for 5.1 patches, Laurent Vivier, 2020/05/04
- [PULL 02/20] display/blizzard: use extract16() for fix clang analyzer warning in blizzard_draw_line16_32(), Laurent Vivier, 2020/05/04
- [PULL 01/20] scsi/esp-pci: add g_assert() for fix clang analyzer warning in esp_pci_io_write(), Laurent Vivier, 2020/05/04
- [PULL 06/20] hw/mem/pc-dimm: Print slot number on error at pc_dimm_pre_plug(), Laurent Vivier, 2020/05/04
- [PULL 09/20] MAINTAINERS: Update Keith Busch's email address, Laurent Vivier, 2020/05/04
- [PULL 03/20] timer/exynos4210_mct: Remove redundant statement in exynos4210_mct_write(), Laurent Vivier, 2020/05/04
- [PULL 13/20] blockdev: Remove dead assignment,
Laurent Vivier <=
- [PULL 04/20] crypto: Redundant type conversion for AES_KEY pointer, Laurent Vivier, 2020/05/04
- [PULL 10/20] chardev: Add macOS to list of OSes that support -chardev serial, Laurent Vivier, 2020/05/04
- [PULL 07/20] hw/mem/pc-dimm: Fix line over 80 characters warning, Laurent Vivier, 2020/05/04
- [PULL 11/20] Compress lines for immediate return, Laurent Vivier, 2020/05/04
- [PULL 14/20] hw/i2c/pm_smbus: Remove dead assignment, Laurent Vivier, 2020/05/04
- [PULL 08/20] elf_ops: Don't try to g_mapped_file_unref(NULL), Laurent Vivier, 2020/05/04
- [PULL 18/20] hw/gpio/aspeed_gpio: Remove dead assignment, Laurent Vivier, 2020/05/04
- [PULL 05/20] MAINTAINERS: Mark the LatticeMico32 target as orphan, Laurent Vivier, 2020/05/04