diff options
| author | Stefan Weil | 2013-06-10 22:12:25 +0200 |
|---|---|---|
| committer | Michael Tokarev | 2013-06-11 21:45:44 +0200 |
| commit | 909a196d2754388d3b15a34b688095c655792124 (patch) | |
| tree | 4a057f7257a5d4d4aa44f184096515eeabd0e055 /device_tree.c | |
| parent | Makefile: Install qemu-img and qemu-nbd man pages only if built (diff) | |
| download | qemu-909a196d2754388d3b15a34b688095c655792124.tar.gz qemu-909a196d2754388d3b15a34b688095c655792124.tar.xz qemu-909a196d2754388d3b15a34b688095c655792124.zip | |
device tree: Fix cppcheck warning
Fix this cppcheck warning:
Checking device_tree.c...
device_tree.c:216: style:
Checking if unsigned variable 'r' is less than zero.
Signed-off-by: Stefan Weil <sw@weilnetz.de>
Signed-off-by: Michael Tokarev <mjt@tls.msk.ru>
Diffstat (limited to 'device_tree.c')
| -rw-r--r-- | device_tree.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/device_tree.c b/device_tree.c index 56af24b397..69be9da8e4 100644 --- a/device_tree.c +++ b/device_tree.c @@ -213,7 +213,7 @@ uint32_t qemu_devtree_get_phandle(void *fdt, const char *path) uint32_t r; r = fdt_get_phandle(fdt, findnode_nofail(fdt, path)); - if (r <= 0) { + if (r == 0) { fprintf(stderr, "%s: Couldn't get phandle for %s: %s\n", __func__, path, fdt_strerror(r)); exit(1); |
