[Qemu-devel] [PATCH] tests: Remove redundant assignment

Fam Zheng posted 1 patch 6 years, 11 months ago
Patches applied successfully (tree, apply log)
git fetch https://github.com/patchew-project/qemu tags/patchew/20170505020430.2305-1-famz@redhat.com
Test checkpatch passed
Test docker passed
Test s390x passed
tests/postcopy-test.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
[Qemu-devel] [PATCH] tests: Remove redundant assignment
Posted by Fam Zheng 6 years, 11 months ago
Signed-off-by: Fam Zheng <famz@redhat.com>
---
 tests/postcopy-test.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/tests/postcopy-test.c b/tests/postcopy-test.c
index de35a18..e86f876 100644
--- a/tests/postcopy-test.c
+++ b/tests/postcopy-test.c
@@ -41,7 +41,7 @@ static bool ufd_version_check(void)
     struct uffdio_api api_struct;
     uint64_t ioctl_mask;
 
-    int ufd = ufd = syscall(__NR_userfaultfd, O_CLOEXEC);
+    int ufd = syscall(__NR_userfaultfd, O_CLOEXEC);
 
     if (ufd == -1) {
         g_test_message("Skipping test: userfaultfd not available");
-- 
2.9.3


Re: [Qemu-devel] [PATCH] tests: Remove redundant assignment
Posted by Eric Blake 6 years, 11 months ago
On 05/04/2017 09:04 PM, Fam Zheng wrote:
> Signed-off-by: Fam Zheng <famz@redhat.com>
> ---
>  tests/postcopy-test.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 

Reviewed-by: Eric Blake <eblake@redhat.com>

> diff --git a/tests/postcopy-test.c b/tests/postcopy-test.c
> index de35a18..e86f876 100644
> --- a/tests/postcopy-test.c
> +++ b/tests/postcopy-test.c
> @@ -41,7 +41,7 @@ static bool ufd_version_check(void)
>      struct uffdio_api api_struct;
>      uint64_t ioctl_mask;
>  
> -    int ufd = ufd = syscall(__NR_userfaultfd, O_CLOEXEC);
> +    int ufd = syscall(__NR_userfaultfd, O_CLOEXEC);
>  
>      if (ufd == -1) {
>          g_test_message("Skipping test: userfaultfd not available");
> 

-- 
Eric Blake, Principal Software Engineer
Red Hat, Inc.           +1-919-301-3266
Virtualization:  qemu.org | libvirt.org

Re: [Qemu-devel] [PATCH] tests: Remove redundant assignment
Posted by Michael Tokarev 6 years, 11 months ago
That's a good one :)

Applied to -trivial, thanks!

/mjt