- 11 11月, 2016 2 次提交
-
-
由 Daniel P. Berrange 提交于
This reverts commit 1f29f3da. Assuming <dt> is always used to document symbols is way too broad, requiring far too many exemptions to be marked to avoid syntax check rules. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
The original libvirt logo was built using what appears to be either Overpass font, or one stylistically very similar (the slanted top of letters like 'l', 't', etc). The newly recreated libvirt logo will use Overpass. Use this font for the website text too, to provide a consistent style. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 01 11月, 2016 1 次提交
-
-
由 Daniel P. Berrange 提交于
The library.xen file contains a braindump of thoughts dating from the very first days of libvirt, when it was briefly called libxen. This is not useful and potentially misleading or confusing for people. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 13 10月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
This initially started as a fix of some debug printing in virCgroupDetect. However it turned out that other places suffer from the similar problem. While dealing with pids, esp. in cases where we cannot use pid_t for ABI stability reasons, we often chose an unsigned integer type. This makes no sense as pid_t is signed. Also, new syntax-check rule is introduced so we won't repeat this mistake. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 12 10月, 2016 1 次提交
-
-
由 Martin Kletzander 提交于
This way we get reference counting and we can get rid of locking function. Signed-off-by: NMartin Kletzander <mkletzan@redhat.com>
-
- 18 8月, 2016 3 次提交
-
-
由 Ján Tomko 提交于
The marginally nicer error message is not worth the extra lines in cfg.mk. Also drop the excludes since there was only one offender in the tests.
-
由 Ján Tomko 提交于
Both gethostbyaddr and gethostbyname* are already checked by sc_prohibit_nonreentrant.
-
由 Ján Tomko 提交于
GNU make is able to replace characters, no need to call tr.
-
- 26 6月, 2016 1 次提交
-
-
由 Erik Skultety 提交于
Some of the examples make use of asprintf and strtol functions (to keep things simple) which are prohibited to use within our code (enforced by syntax-check). Therefore besides adding some examples, this patch also updates cfg.mk to exclude examples directory from asprintf and strtol rules, as well as updates .gitignore to exclude all the new admin binaries created in the 'examples' dir. Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
- 24 6月, 2016 2 次提交
- 23 6月, 2016 1 次提交
-
-
由 Ján Tomko 提交于
Invoke the script only once instead of once for every file.
-
- 22 6月, 2016 1 次提交
-
-
由 Ján Tomko 提交于
This script can already operate on a list of files. Add a --check parameter to check if multiple files are wrapped correctly with a single invocation of the script.
-
- 16 6月, 2016 1 次提交
-
-
由 Ján Tomko 提交于
This checks forbids using "can not" and checks the placement of some texinfo tags. Drop it since we do not use texinfo and the check takes almost twice as much as the rest of the checks.
-
- 15 6月, 2016 2 次提交
-
-
由 Ján Tomko 提交于
We test whitespace with lots of other characters now.
-
由 Ján Tomko 提交于
The prohibit_nonreentrant syntax-check rule spawns a new shell for every non-reentrant function we know, to make it easier to mention the function name in the error message, with the _r appended. Since the line with the offending function is already printed and some of the functions on our list do not have a _r counterpart, compile them into one big regex and use a more generic error message to save time.
-
- 10 6月, 2016 1 次提交
-
-
由 Daniel P. Berrange 提交于
Move all APIs with a virHostCPU name prefix out into new util/virhostcpu.h & util/virhostcpu.c files Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 24 5月, 2016 1 次提交
-
-
由 Pavel Hrdina 提交于
Fix the regex for excluding files for this syntax-rule. The rule "include/" will not work, because we are matching the whole line like this "^(...|include/|...)$ so we need to use "include/libvirt/libvirt.+". The second issue is that we are using only one '$' but there should be two of those at the end. The last small adjustment is to escape dots '.' so it match only dot. Signed-off-by: NPavel Hrdina <phrdina@redhat.com>
-
- 20 5月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
There is a lot to explain, but I try to make it as short as possible. I'd start by pasting some parts of sys/stat.h: extern int stat (const char *__restrict __file, struct stat *__restrict __buf) __THROW __nonnull ((1, 2)); extern int __REDIRECT_NTH (stat, (const char *__restrict __file, struct stat *__restrict __buf), stat64) __nonnull ((1, 2)); __extern_inline int __NTH (stat (const char *__path, struct stat *__statbuf)) { return __xstat (_STAT_VER, __path, __statbuf); } Only one of these is effective at once, due to some usage of the mess we are dealing with in here. So, basically, while compiling or linking stat() in our code can be transformed into some other func. Or a dragon. Now, if you read stat(2) manpage, esp. "C library/kernel differences" section, you'll learn that glibc uses some tricks for older applications to work. I haven't gotten around actual code that does this, but based on my observations, if 'stat' symbol is found, glibc assumes it's dealing with ancient application. Unfortunately, it can be just ours stat coming from our mock. Therefore, calling stat() from a test will end up in our mock. But since glibc is not exposing the symbol anymore, our call of real_stat() will SIGSEGV immediately as the pointer to function is NULL. Therefore, we should expose only those symbols we know glibc has. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 14 5月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
The intent is that this library is going to be called every time to check if we are not touching anything outside srcdir or builddir. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 25 4月, 2016 1 次提交
-
-
由 Andrea Bolognani 提交于
Commit 61b070cf cleaned up a number of cases where the <dt> element was used to document symbols, but the symbol itself was not inside a <code> element. To make sure we don't end up having to clean up again a few months from now, introduce a syntax-check rule that can spot such mistakes. All existing exceptions are marked as such, with either file or line granularity depending on the case.
-
- 22 4月, 2016 2 次提交
-
-
由 Cole Robinson 提交于
And confdata to virconfdata, since 'conf' can mean a few different things in libvirt
-
由 Cole Robinson 提交于
$ echo -n 'log_level=1' > ~/.config/libvirt/libvirtd.conf $ libvirtd --timeout=10 2014-10-10 10:30:56.394+0000: 6626: info : libvirt version: 1.1.3.6, package: 1.fc20 (Fedora Project, 2014-09-08-17:50:42, buildvm-05.phx2.fedoraproject.org) 2014-10-10 10:30:56.394+0000: 6626: error : main:1261 : Can't load config file: configuration file syntax error: /home/rjones/.config/libvirt/libvirtd.conf:1: expecting a value: /home/rjones/.config/libvirt/libvirtd.conf Rather than try to fix this in the depths of the parser, just catch the case when a config file doesn't end in a newline, and manually append a newline to the content before parsing https://bugzilla.redhat.com/show_bug.cgi?id=1151409
-
- 18 4月, 2016 1 次提交
-
-
由 Erik Skultety 提交于
Make all relevant changes to admin protocol, in order to achieve $(subj) Signed-off-by: NErik Skultety <eskultet@redhat.com>
-
- 15 4月, 2016 2 次提交
-
-
由 Andrea Bolognani 提交于
To prevent the error messages in cfg.mk from triggering the very same rules they're supposed to explain, we split the message in the middle of a symbol name, ending up with stuff like 'I am a me'ssage Instead of relying on these quotation tricks, simply exclude cfg.mk from the relevant checks.
-
由 Cole Robinson 提交于
Take setlocale/gettext error handling pattern from tools/virsh-* and use it for all standalone binaries via a new shared virGettextInitialize routine. The virsh* pattern differed slightly from other callers. All users now consistently: * Ignore setlocale errors. virsh has done this forever, presumably for good reason. This has been partially responsible for some bug reports: https://bugzilla.redhat.com/show_bug.cgi?id=1312688 https://bugzilla.redhat.com/show_bug.cgi?id=1026514 https://bugzilla.redhat.com/show_bug.cgi?id=1016158 * Report the failed function name * Report strerror
-
- 12 4月, 2016 2 次提交
-
-
由 Andrea Bolognani 提交于
Being consistent is nice, especially when it comes to defining our regular expression, where using single quotes instead of double quotes allows us to leave out a few backslashes. Changing this required altering a few error messages. The only remaining use of double quotes is one where they are actually required for the check to work.
-
由 Andrea Bolognani 提交于
-
- 29 3月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
While we have a wiki page describing the feature [1] since the feature is distributed in our .tar.gz we ought to document it. So I went ahead, copied the wiki page and reformatted so it fits our docs coding style. 1: http://wiki.libvirt.org/page/NSS_moduleSigned-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 24 3月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
After 9c17d665 the tap device for ethernet network type is automatically precreated before spawning qemu. Problem is, the qemuxml2argvtest wasn't updated and thus is failing. Because of all the APIs that new code is calling, I had to mock a lot. Also, since the tap FDs are labeled separately from the rest of the devices/files I had to enable NOP security driver for the test too. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 19 3月, 2016 1 次提交
-
-
由 Michal Privoznik 提交于
A small test to see how is the nss module working. Signed-off-by: NMichal Privoznik <mprivozn@redhat.com>
-
- 12 2月, 2016 1 次提交
-
-
由 Andrea Bolognani 提交于
As mock libraries are not to be linked against libvirt, the sc_prohibit_close syntax-check rule does not apply. This fixes a syntax-check failure introduced by commit a03cbfe0.
-
- 11 2月, 2016 1 次提交
-
-
由 Ján Tomko 提交于
Using strcat directly is more readable than passing strlen of the copied string to strncat.
-
- 03 2月, 2016 1 次提交
-
-
由 Erik Skultety 提交于
There might be cases, like with typed params, where triggering this check isn't desirable. But including the whole module in the exception regex is not always to right way of doing things. By adding an option to manually disable this check on a specific occurrence, the module itself will still be checked against the rule.
-
- 10 1月, 2016 1 次提交
-
-
由 Cole Robinson 提交于
The period makes it more difficult to copy/paste the errant filename for manual fixup
-
- 30 11月, 2015 1 次提交
-
-
由 Erik Skultety 提交于
As it turned out, we need to share some enums and declarations between libvirt.h and libvirt-admin.h, but since our policy forbids direct includes of libvirt*.h, there has to be some header exempt from this rule. This patch moves the relevant part of code from libvirt.h.in to libvirt-common.h.in. Moreover, since there is no need to have libvirt.h generated anymore, introduce a new header libvirt.h which was previosly ignored from git and make the common header ignored and generated instead.
-
- 26 11月, 2015 2 次提交
-
-
由 Daniel P. Berrange 提交于
Currently the QEMU stdout/stderr streams are written directly to a regular file (eg /var/log/libvirt/qemu/$GUEST.log). While those can be rotated by logrotate (using copytruncate option) this is not very efficient. It also leaves open a window of opportunity for a compromised/broken QEMU to DOS the host filesystem by writing lots of text to stdout/stderr. This makes it possible to connect the stdout/stderr file handles to a pipe that is provided by virtlogd. The virtlogd daemon will read from this pipe and write data to the log file, performing file rotation whenever a pre-determined size limit is reached. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
由 Daniel P. Berrange 提交于
Copy the virtlockd codebase across to form the initial virlogd code. Simple search & replace of s/lock/log/ and gut the remote protocol & dispatcher. This gives us a daemon that starts up and listens for connections, but does nothing with them. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-
- 17 11月, 2015 1 次提交
-
-
由 Andrea Bolognani 提交于
This guards against code such as cleanup : which is happily accepted by the compiler but does not conform to our style guidelines.
-
- 09 11月, 2015 1 次提交
-
-
由 Daniel P. Berrange 提交于
Back in commit bd6c46fa Author: Juerg Haefliger <juerg.haefliger@hp.com> Date: Mon Jan 31 06:42:57 2011 -0500 tests: handle backspace-newline pairs in test input files all the test argv files were line wrapped so that the args were less than 80 characters. The way the line wrapping was done turns out to be quite undesirable, because it often leaves multiple parameters on the same line. If we later need to add or remove individual parameters, then it leaves us having to redo line wrapping. This commit changes the line wrapping so that every single "-param value" is one its own new line. If the "value" is still too long, then we break on ',' or ':' or ' ' as needed. This means that when we come to add / remove parameters from the test files line, the patch diffs will only ever show a single line added/removed which will greatly simplify review work. Signed-off-by: NDaniel P. Berrange <berrange@redhat.com>
-