qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] [PATCH v2 1/4] i440fx-test: qtest_start() should be pai


From: Markus Armbruster
Subject: Re: [Qemu-devel] [PATCH v2 1/4] i440fx-test: qtest_start() should be paired with qtest_end()
Date: Fri, 29 Nov 2013 14:23:57 +0100
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/24.2 (gnu/linux)

Laszlo Ersek <address@hidden> writes:

> Similarly to commit 1d9358e6
> ("libqtest: New qtest_end() to go with qtest_start()").
>
> Signed-off-by: Laszlo Ersek <address@hidden>
> ---
>  tests/i440fx-test.c | 10 ++++------
>  1 file changed, 4 insertions(+), 6 deletions(-)
>
> diff --git a/tests/i440fx-test.c b/tests/i440fx-test.c
> index 65c786c..6ac46bf 100644
> --- a/tests/i440fx-test.c
> +++ b/tests/i440fx-test.c
> @@ -2,9 +2,11 @@
>   * qtest I440FX test case
>   *
>   * Copyright IBM, Corp. 2012-2013
> + * Copyright Red Hat, Inc. 2013
>   *
>   * Authors:
>   *  Anthony Liguori   <address@hidden>
> + *  Laszlo Ersek      <address@hidden>
>   *
>   * This work is licensed under the terms of the GNU GPL, version 2 or later.
>   * See the COPYING file in the top-level directory.
> @@ -256,7 +258,6 @@ static void test_i440fx_pam(gconstpointer opaque)
>  
>  int main(int argc, char **argv)
>  {
> -    QTestState *s;
>      TestData data;
>      char *cmdline;
>      int ret;
> @@ -266,20 +267,17 @@ int main(int argc, char **argv)
>      data.num_cpus = 1;
>  
>      cmdline = g_strdup_printf("-smp %d", data.num_cpus);
> -    s = qtest_start(cmdline);
> +    qtest_start(cmdline);
>      g_free(cmdline);
>  
>      data.bus = qpci_init_pc();
>  
>      g_test_add_data_func("/i440fx/defaults", &data, test_i440fx_defaults);
>      g_test_add_data_func("/i440fx/pam", &data, test_i440fx_pam);
> -    
>  
>      ret = g_test_run();
>  
> -    if (s) {
> -        qtest_quit(s);
> -    }
> +    qtest_end();
>  
>      return ret;
>  }

There are a few more mismatched qtest_start()..qtest_quit() pairs
elsewhere.  That's an observation, not a demand :)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]