- 23 9月, 2009 1 次提交
-
-
由 Chris Lalancette 提交于
Add the virStrncpy function, which takes a dst string, source string, the number of bytes to copy and the number of bytes available in the dest string. If the source string is too large to fit into the destination string, including the \0 byte, then no data is copied and the function returns NULL. Otherwise, this function copies n bytes from source into dst, including the \0, and returns a pointer to the dst string. This function is intended to replace all unsafe uses of strncpy in the code base, since strncpy does *not* guarantee that the buffer terminates with a \0. Signed-off-by: NChris Lalancette <clalance@redhat.com>
-
- 15 9月, 2009 2 次提交
-
-
由 Daniel P. Berrange 提交于
* include/libvirt/libvirt.h, include/libvirt/libvirt.h.in: Add virSecretGetUsageType, virSecretGetUsageID and virLookupSecretByUsage * python/generator.py: Mark virSecretGetUsageType, virSecretGetUsageID as not throwing exceptions * qemud/remote.c: Implement dispatch for virLookupSecretByUsage * qemud/remote_protocol.x: Add usage type & ID as attributes of remote_nonnull_secret. Add RPC calls for new public APIs * qemud/remote_dispatch_args.h, qemud/remote_dispatch_prototypes.h, qemud/remote_dispatch_ret.h, qemud/remote_dispatch_table.h, qemud/remote_protocol.c, qemud/remote_protocol.h: Re-generate * src/datatypes.c, src/datatypes.h: Add usageType and usageID as properties of virSecretPtr * src/driver.h: Add virLookupSecretByUsage driver entry point * src/libvirt.c: Implement virSecretGetUsageType, virSecretGetUsageID and virLookupSecretByUsage * src/libvirt_public.syms: Export virSecretGetUsageType, virSecretGetUsageID and virLookupSecretByUsage * src/remote_internal.c: Implement virLookupSecretByUsage entry * src/secret_conf.c, src/secret_conf.h: Remove the virSecretUsageType enum, now in public API. Make volume path mandatory when parsing XML * src/secret_driver.c: Enforce usage uniqueness when defining secrets. Implement virSecretLookupByUsage api method * src/virsh.c: Include usage for secret-list command
-
由 Daniel P. Berrange 提交于
Convert all the secret/storage encryption APIs / wire format to handle UUIDs in raw format instead of non-canonical printable format. Guarentees data format correctness. * docs/schemas/storageencryption.rng: Make UUID mandatory for a secret and validate fully * docs/schemas/secret.rng: Fully validate UUID * include/libvirt/libvirt.h, include/libvirt/libvirt.h.in, Add virSecretLookupByUUID and virSecretGetUUID. Make virSecretGetUUIDString follow normal API design pattern * python/generator.py: Skip generation of virSecretGetUUID, virSecretGetUUIDString and virSecretLookupByUUID * python/libvir.c, python/libvirt-python-api.xml: Manual impl of virSecretGetUUID,virSecretGetUUIDString and virSecretLookupByUUID * qemud/remote.c: s/virSecretLookupByUUIDString/virSecretLookupByUUID/ Fix get_nonnull_secret/make_nonnull_secret to use unsigned char * qemud/remote_protocol.x: Fix remote_nonnull_secret to use a remote_uuid instead of remote_nonnull_string for UUID field. Rename REMOTE_PROC_SECRET_LOOKUP_BY_UUID_STRING to REMOTE_PROC_SECRET_LOOKUP_BY_UUID_STRING and make it take an remote_uuid value * qemud/remote_dispatch_args.h, qemud/remote_dispatch_prototypes.h, qemud/remote_dispatch_ret.h, qemud/remote_dispatch_table.h, qemud/remote_protocol.c, qemud/remote_protocol.h: Re-generate * src/datatypes.h, src/datatypes.c: Store UUID in raw format instead of printable. Change virGetSecret to use raw format UUID * src/driver.h: Rename virDrvSecretLookupByUUIDString to virDrvSecretLookupByUUID and use raw format UUID * src/libvirt.c: Add virSecretLookupByUUID and virSecretGetUUID and re-implement virSecretLookupByUUIDString and virSecretGetUUIDString in terms of those * src/libvirt_public.syms: Add virSecretLookupByUUID and virSecretGetUUID * src/remote_internal.c: Rename remoteSecretLookupByUUIDString to remoteSecretLookupByUUID. Fix typo in args for remoteSecretDefineXML impl. Use raw UUID format for get_nonnull_secret and make_nonnull_secret * src/storage_encryption_conf.c, src/storage_encryption_conf.h: Storage UUID in raw format, and require it to be present in XML. Use UUID parser to validate. * secret_conf.h, secret_conf.c: Generate a UUID if none is provided. Storage UUID in raw format. * src/secret_driver.c: Adjust to deal with raw UUIDs. Save secrets in a filed with printable UUID, instead of base64 UUID. * src/virsh.c: Adjust for changed public API contract of virSecretGetUUIDString. * src/storage_Backend.c: DOn't undefine secret we just generated upon successful volume creation. Fix to handle raw UUIDs. Generate a non-clashing UUID * src/qemu_driver.c: Change to use lookupByUUID instead of lookupByUUIDString
-
- 02 9月, 2009 1 次提交
-
-
由 Miloslav Trmač 提交于
* include/libvirt/virterror.h, src/virterror.c: Add VIR_WAR_NO_SECRET * src/libvirt_private.syms, src/datatypes.h, src/datatypes.c: Type virSecret struct definition and helper APIs * src/driver.h: Sub-driver API definitions for secrets * src/libvirt.c: Define new sub-driver for secrets
-
- 18 8月, 2009 1 次提交
-
-
由 Chris Lalancette 提交于
Currently the reference counting for connections is busted. I first noticed it while trying to use virConnectRef; it would eventually cause a crash in the remote_internal driver, although that was really just a victim. Really, we should only call the close callbacks on the methods when the references drop to 0. To accomplish this, move all of the close callbacks into virUnrefConnect (since there are lots of internal users of that function), and arrange for virConnectClose to call that. V2: Make sure to drop the connection lock before we call the close callbacks, otherwise we could deadlock the daemon V3: Fix up a crash when we got an error from one of the drivers Signed-off-by: NChris Lalancette <clalance@redhat.com>
-
- 24 7月, 2009 1 次提交
-
-
由 Laine Stump 提交于
* src/datatypes.c src/domain_conf.c src/interface_conf.c src/lxc_driver.c src/qemu_driver.c src/storage_backend.c src/virsh.c: add bare %s format string to printf-derivatives called with no format string
-
- 23 7月, 2009 1 次提交
-
-
由 Laine Stump 提交于
* src/datatypes.c: more cleanup, where lock must be released before calling error handling which tries to get it.
-
- 22 7月, 2009 2 次提交
-
-
由 Laine Stump 提交于
* src/datatypes.c: fix a lock problem on error handling, as the error report takes the lock, it must be released before, fixes the problem but just for Interface objects
-
由 Laine Stump 提交于
* src/datatypes.c: handle the nasty case where an interface mac address change, while it's already in use
-
- 21 7月, 2009 1 次提交
-
-
由 Laine Stump 提交于
MAC address of a particular interface may change over time, and the reduced virInterface object (which contains just name and mac) needs to reflect these changes. Since we can't modify the mac address of an existing virInterface (some other thread may currently be using it) we just create a new virInterface, and let the old one die a dignified death when its refct goes to 0. * src/datatypes.c: fix the matching and lifetime of virInterface object accordingly
-
- 29 5月, 2009 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 20 5月, 2009 1 次提交
-
-
由 Daniel Veillard 提交于
* configure.in include/libvirt/libvirt.h[.in] include/libvirt/virterror.h qemud/remote.c qemud/remote_dispatch_args.h qemud/remote_dispatch_prototypes.h qemud/remote_dispatch_ret.h qemud/remote_dispatch_table.h qemud/remote_protocol.[chx] src/Makefile.am src/datatypes.c src/datatypes.h src/driver.h src/libvirt.c src/remote_internal.c src/virterror.c src/libvirt_private.syms src/libvirt_public.syms: Add the Interface config APIs and remote stubs for those, patch by Laine Stump * AUTHORS: add Laine daniel
-
- 11 5月, 2009 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 01 4月, 2009 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 29 1月, 2009 1 次提交
-
-
由 Jim Meyering 提交于
* src/uml_conf.c (VIR_FROM_THIS): Define to VIR_FROM_UML. * src/xs_internal.c (VIR_FROM_THIS): Define to VIR_FROM_XEN. * src/xml.c (VIR_FROM_THIS): Define to VIR_FROM_XML. * src/stats_linux.c (VIR_FROM_THIS): Define to VIR_FROM_STATS_LINUX. * src/datatypes.c (VIR_FROM_THIS): Define to VIR_FROM_NONE. * src/lxc_conf.c (VIR_FROM_THIS): Define to VIR_FROM_LXC. * src/libvirt.c (VIR_FROM_THIS): Define to VIR_FROM_NONE. * src/node_device_conf.c (VIR_FROM_THIS): Define to VIR_FROM_NODEDEV. * src/openvz_conf.c (VIR_FROM_THIS): Define to VIR_FROM_OPENVZ. * src/openvz_driver.c (VIR_FROM_THIS): Define to VIR_FROM_OPENVZ. * src/conf.c (VIR_FROM_THIS): Define to VIR_FROM_CONF. Note: this loses config_filename:config_lineno diagnostics, but that's ok. * src/node_device.c (VIR_FROM_THIS): Define to VIR_FROM_NODEDEV. * src/sexpr.c (VIR_FROM_THIS): Define to VIR_FROM_SEXPR. * po/POTFILES.in: remove src/sexpr.c and src/lxc_conf.c
-
- 20 1月, 2009 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 16 1月, 2009 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 05 12月, 2008 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 21 11月, 2008 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 17 11月, 2008 2 次提交
-
-
由 Daniel P. Berrange 提交于
-
由 Daniel P. Berrange 提交于
-
- 07 11月, 2008 1 次提交
-
-
由 Daniel Veillard 提交于
* src/logging.c src/logging.h proxy/Makefile.am proxy/libvirt_proxy.c src/Makefile.am src/cgroup.c src/datatypes.c src/domain_event.c src/internal.h src/libvirt.c src/lxc_container.c src/lxc_controller.c src/lxc_driver.c src/proxy_internal.c src/qemu_driver.c src/remote_internal.c src/storage_backend_disk.c src/util.c src/veth.c src/xen_internal.c src/xen_unified.c src/xend_internal.c: add new logging module, and move existing definitions there Daniel
-
- 05 11月, 2008 2 次提交
-
-
由 Daniel P. Berrange 提交于
-
由 Daniel P. Berrange 提交于
-
- 14 10月, 2008 1 次提交
-
-
由 Jim Meyering 提交于
Building with --disable-nls exposed many new warnings like these: virsh.c:4952: warning: format not a string literal and no format ... util.c:163: warning: format not a string literal and no format arguments All but one of the following changes add a "%s" argument before the offending _(...) argument. This was the only manual change: * src/lxc_driver.c (lxcVersion): Use %s and strerror(errno) rather than %m, to avoid a warning from gcc -Wformat-security. Add "%s" before each warned about format-string-with-no-%-directive: * src/domain_conf.c (virDomainHostdevSubsysUsbDefParseXML) (virDomainDefParseString, virDomainDefParseFile): * src/hash.c (virGetConnect, __virGetDomain, virReleaseDomain) (__virGetNetwork, virReleaseNetwork, __virGetStoragePool) (virReleaseStoragePool, __virGetStorageVol, virReleaseStorageVol): * src/lxc_container.c (lxcContainerChild): * src/lxc_driver.c (lxcDomainDefine, lxcDomainUndefine) (lxcDomainGetInfo, lxcGetOSType, lxcDomainDumpXML) (lxcSetupInterfaces, lxcDomainStart, lxcDomainCreateAndStart) (lxcVersion, lxcGetSchedulerParameters): * src/network_conf.c (virNetworkDefParseString) (virNetworkDefParseFile): * src/openvz_conf.c (openvzReadNetworkConf, openvzLoadDomains): * src/openvz_driver.c (openvzDomainDefineCmd) (openvzDomainGetInfo, openvzDomainDumpXML, openvzDomainShutdown) (openvzDomainReboot, ADD_ARG_LIT, openvzDomainDefineXML) (openvzDomainCreateXML, openvzDomainCreate, openvzDomainUndefine) (openvzDomainSetAutostart, openvzDomainGetAutostart) (openvzDomainSetVcpus): * src/qemu_driver.c (qemudDomainBlockPeek, qemudDomainMemoryPeek): * src/remote_internal.c (remoteDomainBlockPeek) (remoteDomainMemoryPeek, remoteAuthPolkit): * src/sexpr.c (sexpr_new, _string2sexpr): * src/storage_backend_disk.c (virStorageBackendDiskMakeDataVol) (virStorageBackendDiskCreateVol): * src/storage_backend_fs.c (virStorageBackendFileSystemNetFindPoolSources): * src/storage_backend_logical.c (virStorageBackendLogicalFindLVs) (virStorageBackendLogicalFindPoolSources): * src/test.c (testOpenDefault, testOpenFromFile, testOpen) (testGetDomainInfo, testDomainRestore) (testNodeGetCellsFreeMemory): * src/util.c (virExec): * src/virsh.c (cmdAttachDevice, cmdDetachDevice) (cmdAttachInterface, cmdDetachInterface, cmdAttachDisk) (cmdDetachDisk, cmdEdit): * src/xend_internal.c (do_connect, wr_sync, xend_op_ext) (urlencode, xenDaemonDomainCreateXML) (xenDaemonDomainLookupByName_ids, xenDaemonDomainLookupByID) (xenDaemonParseSxprOS, xend_parse_sexp_desc_char) (xenDaemonParseSxprChar, xenDaemonParseSxprDisks) (xenDaemonParseSxpr, sexpr_to_xend_topology, sexpr_to_domain) (xenDaemonDomainFetch, xenDaemonDomainGetAutostart) (xenDaemonDomainSetAutostart, xenDaemonDomainMigratePerform) (xenDaemonDomainDefineXML, xenDaemonGetSchedulerType) (xenDaemonGetSchedulerParameters) (xenDaemonSetSchedulerParameters, xenDaemonDomainBlockPeek) (xenDaemonFormatSxprChr, virDomainXMLDevID): * src/xm_internal.c (xenXMConfigCacheRefresh, xenXMDomainPinVcpu) (xenXMDomainCreate, xenXMDomainDefineXML) (xenXMDomainAttachDevice, xenXMDomainDetachDevice): * src/xml.c (virXPathString, virXPathNumber, virXPathLong) (virXPathULong, virXPathBoolean, virXPathNode, virXPathNodeSet): * src/xs_internal.c (xenStoreOpen):
-
- 09 10月, 2008 1 次提交
-
-
由 Cole Robinson 提交于
-
- 07 10月, 2008 1 次提交
-
-
由 Cole Robinson 提交于
-
- 22 5月, 2008 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 15 5月, 2008 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 29 4月, 2008 2 次提交
-
-
由 Daniel P. Berrange 提交于
-
由 Daniel P. Berrange 提交于
-
- 18 4月, 2008 1 次提交
-
-
由 Richard W.M. Jones 提交于
* configure.in: Fix pkg-config detection of libxml2, add -lgcrypt to gnutls lib. * src/Makefile.am: If compiling --without-libvirtd then don't compile any part of the storage driver. * configure.in, src/hash.c, src/internal.h: Detect availability of pthread library and compile out mutex code if not available. * src/storage_driver.c, src/util.c: Ignore some missing headers on MinGW.
-
- 11 4月, 2008 1 次提交
-
-
由 Jim Meyering 提交于
Done with these commands: git grep -l Local.variab|xargs \ perl -0x3b -pi -e 's,\n+/\*\n \* vim:(.|\n)*,\n,' git grep -l Local.variab|xargs \ perl -0x3b -pi -e 's,\n+/\*\n \* Local variables:\n(.|\n)*,\n,'
-
- 04 4月, 2008 1 次提交
-
-
由 Daniel Veillard 提交于
* docs//* src/conf.c src/hash.c src/libvirt.c src/proxy_internal.c src/remote_internal.c src/virsh.c src/xen_internal.c src/xend_internal.c src/xml.c: applied patch from Atsushi SAKAI fixing a lot of typos Daniel
-
- 31 3月, 2008 1 次提交
-
-
由 Daniel Veillard 提交于
* src/hash.c src/internal.h src/virterror.c: remove dandling domain/net/conn pointers from error data when released. * src/lxc_driver.c: fix a NULL/0 return error mismatch Daniel
-
- 20 2月, 2008 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 08 2月, 2008 1 次提交
-
-
由 Daniel Veillard 提交于
* src/hash.c: fix a couple of problems in virHashRemoveSet based on Hiroyuki Kaguchi patch and explanations. Daniel
-
- 06 2月, 2008 1 次提交
-
-
由 Jim Meyering 提交于
* Makefile.cfg (local-checks-to-skip): Remove sc_trailing_blank. * .x-sc_trailing_blank: New file, to exempt the few binary files.
-
- 31 1月, 2008 1 次提交
-
-
由 Daniel P. Berrange 提交于
-
- 30 1月, 2008 1 次提交
-
-
由 Jim Meyering 提交于
Use <config.h>, not "config.h", per autoconf documentation. * Makefile.cfg (local-checks-to-skip) [sc_require_config_h]: Enable. * .x-sc_require_config_h: New file, to list exempted files. * Makefile.am (EXTRA_DIST): Add .x-sc_require_config_h.
-