~serge-hallyn/ubuntu/raring/libvirt/libvirt-virbr0

« back to all changes in this revision

Viewing changes to src/util/virfile.h

  • Committer: Package Import Robot
  • Author(s): Chuck Short
  • Date: 2012-05-13 15:44:12 UTC
  • mfrom: (1.2.13)
  • Revision ID: package-import@ubuntu.com-20120513154412-fgmn5sxqdzgnzlx3
Tags: 0.9.12-0ubuntu1
* New upstream version:
  * Synchronize with debian packaging:
    - debian/control: Update build depends.
    - debian/libvirt-bin.postrm: Cleanup /var/log/libvirt
      on purge.
    - Bump standards verson (no changes).
    - debian/patches/Don-t-fail-if-we-can-t-setup-avahi.patch: Added
  * Dropped patches:
    - debian/patches/Debianize-libvirt-guests.patch
    - debian/patches/rewrite-lxc-controller-eof-handling-yet-again
    - debian/patches/ubuntu/libnl13.patch
    - debian/patches/ubuntu/fix-lxc-startup-error.patch
    - debian/patches/ubuntu/fix-bridge-fd.patch
    - debian/patches/ubuntu/skip-labelling-network-disks.patch
    - debian/patches/ubuntu/xen-xend-shutdown-detection.patch
    - debian/patches/ubuntu/xen-config-no-vfb-for-hvm.patch
    - debian/patches/debian/Disable-daemon-start-test.patch
    - debian/patches/debian/Disable-gnulib-s-test-nonplocking-pipe.sh.patch
    - debian/patches/ubuntu/9006-default-config-test-case.patch
    - debian/patches/fix-block-migration.patch
    - debian/patches/ubuntu/9022-qemu-unescape-HMP-commands-before-converting-them-to.patch
    - debian/patches/ubuntu/9023-qemu-change-rbd-auth_supported-separation-character-.patch
    - debian/patches/ubuntu/9024-qemu-allow-snapshotting-of-sheepdog-and-rbd-disks.patch
    - debian/patches/9025-qemu-change-rbd-auth_supported-separation-character-.patch
    - debian/patches/ubuntu/arm-gcc-workaround.patch
  * Rediffed:
    - debian/patches/Allow-libvirt-group-to-access-the-socket.patch
    - debian/patches/Disable-failing-virnetsockettest.patch
    - debian/patches/dnsmasq-as-priv-user
    - debian/patches/9002-better_default_uri_virsh.patch
  * debian/control: Add libnl-route-3-dev ass a build depends.
  * debian/patches/libnl3-build-fix.patch: Fix build with libnl3.

Show diffs side-by-side

added added

removed removed

Lines of Context:
50
50
# define VIR_FORCE_CLOSE(FD) ignore_value(virFileClose(&(FD), true))
51
51
# define VIR_FORCE_FCLOSE(FILE) ignore_value(virFileFclose(&(FILE), true))
52
52
 
53
 
/* Opaque type for managing a wrapper around an O_DIRECT fd.  */
54
 
struct _virFileDirectFd;
 
53
/* Opaque type for managing a wrapper around a fd.  */
 
54
struct _virFileWrapperFd;
55
55
 
56
 
typedef struct _virFileDirectFd virFileDirectFd;
57
 
typedef virFileDirectFd *virFileDirectFdPtr;
 
56
typedef struct _virFileWrapperFd virFileWrapperFd;
 
57
typedef virFileWrapperFd *virFileWrapperFdPtr;
58
58
 
59
59
int virFileDirectFdFlag(void);
60
60
 
61
 
virFileDirectFdPtr virFileDirectFdNew(int *fd, const char *name)
 
61
enum virFileWrapperFdFlags {
 
62
    VIR_FILE_WRAPPER_BYPASS_CACHE   = (1 << 0),
 
63
    VIR_FILE_WRAPPER_NON_BLOCKING   = (1 << 1),
 
64
};
 
65
 
 
66
virFileWrapperFdPtr virFileWrapperFdNew(int *fd,
 
67
                                        const char *name,
 
68
                                        unsigned int flags)
62
69
    ATTRIBUTE_NONNULL(1) ATTRIBUTE_NONNULL(2) ATTRIBUTE_RETURN_CHECK;
63
70
 
64
 
int virFileDirectFdClose(virFileDirectFdPtr dfd);
 
71
int virFileWrapperFdClose(virFileWrapperFdPtr dfd);
65
72
 
66
 
void virFileDirectFdFree(virFileDirectFdPtr dfd);
 
73
void virFileWrapperFdFree(virFileWrapperFdPtr dfd);
67
74
 
68
75
int virFileLock(int fd, bool shared, off_t start, off_t len);
69
76
int virFileUnlock(int fd, off_t start, off_t len);
74
81
                   virFileRewriteFunc rewrite,
75
82
                   void *opaque);
76
83
 
 
84
int virFileTouch(const char *path, mode_t mode);
 
85
 
 
86
int virFileUpdatePerm(const char *path,
 
87
                      mode_t mode_remove,
 
88
                      mode_t mode_add);
 
89
 
77
90
#endif /* __VIR_FILES_H */