1. 02 1月, 2019 3 次提交
  2. 19 12月, 2018 1 次提交
  3. 18 12月, 2018 4 次提交
  4. 17 12月, 2018 2 次提交
    • D
      qemu: use line breaks in command line args written to log · 07c9d660
      Daniel P. Berrangé 提交于
      The QEMU command line arguments are very long and currently all written
      on a single line to /var/log/libvirt/qemu/$GUEST.log. This introduces
      logic to add line breaks after every env variable and "-" optional
      argument, and every positional argument. This will create a clearer log
      file, which will in turn present better in bug reports when people cut +
      paste from the log into a bug comment.
      
      An example log file entry now looks like this:
      
        2018-12-14 12:57:03.677+0000: starting up libvirt version: 5.0.0, qemu version: 3.0.0qemu-3.0.0-1.fc29, kernel: 4.19.5-300.fc29.x86_64, hostname: localhost.localdomain
        LC_ALL=C \
        PATH=/usr/local/bin:/usr/local/sbin:/usr/bin:/usr/sbin \
        HOME=/home/berrange \
        USER=berrange \
        LOGNAME=berrange \
        QEMU_AUDIO_DRV=none \
        /usr/bin/qemu-system-ppc64 \
        -name guest=guest,debug-threads=on \
        -S \
        -object secret,id=masterKey0,format=raw,file=/home/berrange/.config/libvirt/qemu/lib/domain-33-guest/master-key.aes \
        -machine pseries-2.10,accel=tcg,usb=off,dump-guest-core=off \
        -m 1024 \
        -realtime mlock=off \
        -smp 1,sockets=1,cores=1,threads=1 \
        -uuid c8a74977-ab18-41d0-ae3b-4041c7fffbcd \
        -display none \
        -no-user-config \
        -nodefaults \
        -chardev socket,id=charmonitor,fd=23,server,nowait \
        -mon chardev=charmonitor,id=monitor,mode=control \
        -rtc base=utc \
        -no-shutdown \
        -boot strict=on \
        -device qemu-xhci,id=usb,bus=pci.0,addr=0x1 \
        -device virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x2 \
        -sandbox on,obsolete=deny,elevateprivileges=deny,spawn=deny,resourcecontrol=deny \
        -msg timestamp=on
        2018-12-14 12:57:03.730+0000: shutting down, reason=failed
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      07c9d660
    • D
      util: require command args to be non-NULL · 912c6b22
      Daniel P. Berrangé 提交于
      The virCommand APIs do not expect to be given a NULL value for an arg
      name or value. Such a mistake can lead to execution of the wrong
      command, as the NULL may prematurely terminate the list of args.
      Detect this and report suitable error messages.
      
      This identified a flaw in the storage test which was passing a NULL
      instead of the volume path. This flaw was then validated by an incorrect
      set of qemu-img args as expected data.
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      912c6b22
  5. 14 12月, 2018 5 次提交
    • P
      tests: Add test for virErrorMsg message constraints · d9baf0d7
      Peter Krempa 提交于
      Make sure that we don't add any broken error message strings any more.
      
      This ensures that both the version with and without additional info is
      populated, the version without info does not have any formatting
      modifiers and the version with info has exactly one.
      Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
      Reviewed-by: NErik Skultety <eskultet@redhat.com>
      d9baf0d7
    • D
      Enforce a standard header file guard symbol name · 568a4172
      Daniel P. Berrangé 提交于
      Require that all headers are guarded by a symbol named
      
        LIBVIRT_$FILENAME
      
      where $FILENAME is the uppercased filename, with all characters
      outside a-z changed into '_'.
      
      Note we do not use a leading __ because that is technically a
      namespace reserved for the toolchain.
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      568a4172
    • D
      Fix many mistakes & inconsistencies in header file layout · 4cfd7090
      Daniel P. Berrangé 提交于
      This introduces a syntax-check script that validates header files use a
      common layout:
      
        /*
         ...copyright header...
         */
        <one blank line>
        #ifndef SYMBOL
        # define SYMBOL
        ....content....
        #endif /* SYMBOL */
      
      For any file ending priv.h, before the #ifndef, we will require a
      guard to prevent bogus imports:
      
        #ifndef SYMBOL_ALLOW
        # error ....
        #endif /* SYMBOL_ALLOW */
        <one blank line>
      
      The many mistakes this script identifies are then fixed.
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      4cfd7090
    • J
      storage: Fix build issue with MOUNT and VGCHANGE commands · e6f53e7a
      John Ferlan 提交于
      Turns out there some build platforms that must not define MOUNT
      or VGCHANGE in config.h... So moving the commands from the storage
      backend specific module into a common storage_util module causes
      issues for those platforms.
      
      So instead of assuming they are there, let's just pass the command
      string to the storage util API's from the storage backend specific
      code (as would have been successful before).  Also modify the test
      to determine whether the MOUNT and/or VGCHANGE doesn't exist and
      just define it to (for example) what Fedora has for the path. Could
      have just used "mount" and "vgchange" in the call, but that defeats
      the purpose of adding the call to virTestClearCommandPath.
      Signed-off-by: NJohn Ferlan <jferlan@redhat.com>
      e6f53e7a
    • D
      Remove all Author(s): lines from source file headers · 60046283
      Daniel P. Berrangé 提交于
      In many files there are header comments that contain an Author:
      statement, supposedly reflecting who originally wrote the code.
      In a large collaborative project like libvirt, any non-trivial
      file will have been modified by a large number of different
      contributors. IOW, the Author: comments are quickly out of date,
      omitting people who have made significant contribitions.
      
      In some places Author: lines have been added despite the person
      merely being responsible for creating the file by moving existing
      code out of another file. IOW, the Author: lines give an incorrect
      record of authorship.
      
      With this all in mind, the comments are useless as a means to identify
      who to talk to about code in a particular file. Contributors will always
      be better off using 'git log' and 'git blame' if they need to  find the
      author of a particular bit of code.
      
      This commit thus deletes all Author: comments from the source and adds
      a rule to prevent them reappearing.
      
      The Copyright headers are similarly misleading and inaccurate, however,
      we cannot delete these as they have legal meaning, despite being largely
      inaccurate. In addition only the copyright holder is permitted to change
      their respective copyright statement.
      Reviewed-by: NErik Skultety <eskultet@redhat.com>
      Signed-off-by: NDaniel P. Berrangé <berrange@redhat.com>
      60046283
  6. 13 12月, 2018 5 次提交
  7. 12 12月, 2018 3 次提交
  8. 07 12月, 2018 3 次提交
  9. 06 12月, 2018 2 次提交
  10. 05 12月, 2018 1 次提交
  11. 03 12月, 2018 5 次提交
  12. 29 11月, 2018 2 次提交
  13. 28 11月, 2018 4 次提交