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

Re: [libvirt] [PATCH v3 1/3] virFile: Add APIs for extended attributes handling



On Mon, Mar 11, 2013 at 05:13:27PM +0100, Michal Privoznik wrote:
> Currently, only three wrappers are being implemented:
> virFileSetAttr for setting attributes
> virFileGetAttr for querying attributes (note we need to call it twice,
> first time to get length of attribute value, second to get actual value)
> virFileRemoveAttr for removing attributes
> ---
> 
> diff to v2:
> -drop multiple check for libattr
> 
>  src/libvirt_private.syms |   3 ++
>  src/util/virfile.c       | 106 +++++++++++++++++++++++++++++++++++++++++++++++
>  src/util/virfile.h       |  12 ++++++
>  3 files changed, 121 insertions(+)
> 
> diff --git a/src/libvirt_private.syms b/src/libvirt_private.syms
> index 599b71e..f787a12 100644
> --- a/src/libvirt_private.syms
> +++ b/src/libvirt_private.syms
> @@ -1273,8 +1273,11 @@ virFileClose;
>  virFileDirectFdFlag;
>  virFileFclose;
>  virFileFdopen;
> +virFileGetAttr;
>  virFileLoopDeviceAssociate;
> +virFileRemoveAttr;
>  virFileRewrite;
> +virFileSetAttr;
>  virFileTouch;
>  virFileUpdatePerm;
>  virFileWrapperFdClose;
> diff --git a/src/util/virfile.c b/src/util/virfile.c
> index 4a9fa81..aae7101 100644
> --- a/src/util/virfile.c
> +++ b/src/util/virfile.c
> @@ -37,6 +37,11 @@
>  # include <sys/ioctl.h>
>  #endif
>  
> +#ifdef HAVE_LIBATTR
> +# include <attr/xattr.h>
> +# include <sys/types.h>

sys/types.h should never be required for any functionality - headers
are self-contained.

ACK if that is removed

Daniel
-- 
|: http://berrange.com      -o-    http://www.flickr.com/photos/dberrange/ :|
|: http://libvirt.org              -o-             http://virt-manager.org :|
|: http://autobuild.org       -o-         http://search.cpan.org/~danberr/ :|
|: http://entangle-photo.org       -o-       http://live.gnome.org/gtk-vnc :|


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