[libvirt] [PATCH v4 1/8] virpcimock: Adapt to virmock.h

Peter Krempa pkrempa at redhat.com
Fri May 13 16:13:46 UTC 2016


On Fri, May 13, 2016 at 14:32:02 +0200, Michal Privoznik wrote:
> Instead of introducing our own wrapper for dlsym()
> we can use the one provided by virmock.h.
> 
> Signed-off-by: Michal Privoznik <mprivozn at redhat.com>
> ---
>  tests/virmock.h    | 10 ++++++
>  tests/virpcimock.c | 97 ++++++++++++++++++++++--------------------------------
>  2 files changed, 50 insertions(+), 57 deletions(-)
> 

[...]

> diff --git a/tests/virpcimock.c b/tests/virpcimock.c
> index cfe42a6..c7786e5 100644
> --- a/tests/virpcimock.c
> +++ b/tests/virpcimock.c
> @@ -21,10 +21,7 @@
>  #include <config.h>
>  
>  #ifdef __linux__
> -# include "internal.h"
> -# include <stdio.h>
> -# include <dlfcn.h>
> -# include <stdlib.h>

stdio.h (fprintf) and stdlib.h (abort) are still used by this file so
you probably should not remove the headers.

> +# include "virmock.h"
>  # include <unistd.h>
>  # include <fcntl.h>
>  # include <sys/stat.h>

ACK to the rest.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://listman.redhat.com/archives/libvir-list/attachments/20160513/64718941/attachment-0001.sig>


More information about the libvir-list mailing list