[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PULL 0/4] coverity: Improve and extend model
From: |
Markus Armbruster |
Subject: |
Re: [Qemu-devel] [PULL 0/4] coverity: Improve and extend model |
Date: |
Thu, 12 Feb 2015 10:11:45 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3 (gnu/linux) |
Paolo Bonzini <address@hidden> writes:
> \>> It seems like Coverity Scan doesn't like the new model. Possibly the
>>> fault of the third patch.
>>
>> Works for me with a local 7.0.3 installation. Which I just realized is
>> outdated. I'll recheck with 7.6.0.
>>
>>> Will check (for now I'm still running scans
>>> with the old model).
>>
>> Appreciated.
>
> Yes, the last patch seems to be the culprit. It failed immediately with
> the __coverity_mark_as_afm_freed__(ptr, "g_free") model;
Any diagnostics?
Works for me locally with 7.6.0, and matches the reference manual's
examples for the ALLOC_FREE_MISMATCH checker.
> it's been
> running for a while without it even though it's not done yet.
>
> Perhaps we can do something like this:
>
> /* Some helpful comment here. */
> #if 1
> #define AFM_g_free AFM_free
> #else
> #define AFM_g_free "g_free"
> #endif
Yes. If you want me to write the helpful comment, I need to know what
exactly goes wrong.
The alternative is to revert the patch for now.
Aside: would be nice if Coverity pre-defined a symbol when
ALLOC_FREE_MISMATCH is enabled, it would let me enable support for the
checker exactly when it's wanted.
- [Qemu-devel] [PULL 4/4] MAINTAINERS: Add myself as Coverity model maintainer, (continued)
- [Qemu-devel] [PULL 4/4] MAINTAINERS: Add myself as Coverity model maintainer, Markus Armbruster, 2015/02/05
- [Qemu-devel] [PULL 1/4] coverity: Improve model for GLib memory allocation, Markus Armbruster, 2015/02/05
- [Qemu-devel] [PULL 3/4] coverity: Model g_free() isn't necessarily free(), Markus Armbruster, 2015/02/05
- [Qemu-devel] [PULL 2/4] coverity: Model GLib string allocation partially, Markus Armbruster, 2015/02/05
- Re: [Qemu-devel] [PULL 0/4] coverity: Improve and extend model, Peter Maydell, 2015/02/05