1. 25 4月, 2018 3 次提交
    • D
      driver: tighten check for whether loadable module exists or not · d94640dd
      Daniel P. Berrangé 提交于
      Currently we do a access(R_OK) check to see whether a loadable module
      exists, treating failure as non-fatal. This is unreasonably loose, as a
      module which exists but has had incorrect permissions set will turn into
      a silent skip. We only want to skip loading if the module genuinely does
      not exist on disk, due to the optional package not being installed.
      
      Furthermore, checking the return value of virDriverLoadModuleFile() is
      not a suitable witness that the module does not exist. This method can
      return NULL if dlopen() fails, for example due to being unable to
      resolve symbols in the library. This is should always be reported as an
      error because it is a sign of the bad installation where either the
      module build doesn't match the libvirtd build, or where some 3rd party
      libraries are missing or broken.
      
      Both these problems can be fixed by using virFileExists in the caller
      instead.
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      d94640dd
    • D
      driver: fix handling of error return from finding resource · 2902b764
      Daniel P. Berrangé 提交于
      The virFileFindResource method merely builds up the expected fully
      qualified path to the resource. It does not actually check if it exists
      on disk. The loadable module callers were mistakenly thinking a NULL
      indicates the file doesn't exist on disk, whereas it in fact indicates
      an out of memory error.
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      2902b764
    • D
      driver: don't keep a pointer to the loaded library handle · 96a72f34
      Daniel P. Berrangé 提交于
      Now that we've activated two hacks to prevent unloading of modules,
      there is no point passing back a pointer to the loaded library handle.
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      96a72f34
  2. 24 4月, 2018 8 次提交
  3. 23 4月, 2018 7 次提交
  4. 21 4月, 2018 1 次提交
    • J
      tests: Xen: use qemu-system-i386 for emulator · cec1022e
      Jim Fehlig 提交于
      Many of the old xm and sexpr test files used qemu-dm as the emulator.
      Modern Xen systems no longer use the old, forked qemu-dm, instead
      preferring the distro provided qemu or an "upstream" qemu that is
      built when the Xen tools are built. This qemu is typically installed
      in /usr/lib/xen/bin/qemu-system-i386.
      
      The libxl test files already use /usr/lib/xen/bin/qemu-system-i386.
      For consistency, change the old test files to use the same emulator
      Signed-off-by: NJim Fehlig <jfehlig@suse.com>
      Reviewed-by: NJán Tomko <jtomko@redhat.com>
      cec1022e
  5. 20 4月, 2018 21 次提交