Re: [PATCH] Fix compile errors in remote.c and newly added audit code

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2010/10/19 Eric Blake <eblake@xxxxxxxxxx>:
> On 10/19/2010 11:06 AM, Matthias Bolte wrote:
>>
>> ---
>>
>> I pushed this under the trivial complie error fix rule :)
>
> Thanks.
>
>> @@ -80,7 +80,7 @@ void virAuditSend(const char *file ATTRIBUTE_UNUSED,
>> const char *func, size_t li
>> Âvoid virAuditSend(const char *file ATTRIBUTE_UNUSED, const char *func,
>> size_t linenr,
>> Â Â Â Â Â Â Â Â Â Âconst char *clienttty ATTRIBUTE_UNUSED,
>> Â Â Â Â Â Â Â Â Â Âconst char *clientaddr ATTRIBUTE_UNUSED,
>> - Â Â Â Â Â Â Â Â Âenum virAuditRecordType type, bool success,
>> + Â Â Â Â Â Â Â Â Âenum virAuditRecordType type ATTRIBUTE_UNUSED, bool
>> success,
>> Â Â Â Â Â Â Â Â Â Âconst char *fmt, ...)
>> Â#endif
>
> Hmm - ATTRIBUTE_UNUSED is an indication that on some paths, the variable
> might not be used; and not a requirement that it must not be used. Would
> anyone object to this followup, for one less #ifdef?
>
> diff --git i/src/util/virtaudit.c w/src/util/virtaudit.c
> index 965a6e8..3226961 100644
> --- i/src/util/virtaudit.c
> +++ w/src/util/virtaudit.c
> @@ -71,18 +71,12 @@ void virAuditLog(int logging)
> Â}
>
>
> -#if HAVE_AUDIT
> -void virAuditSend(const char *file ATTRIBUTE_UNUSED, const char *func,
> size_t linenr,
> - Â Â Â Â Â Â Â Â Âconst char *clienttty, const char *clientaddr,
> - Â Â Â Â Â Â Â Â Âenum virAuditRecordType type, bool success,
> - Â Â Â Â Â Â Â Â Âconst char *fmt, ...)
> -#else
> -void virAuditSend(const char *file ATTRIBUTE_UNUSED, const char *func,
> size_t linenr,
> +void virAuditSend(const char *file ATTRIBUTE_UNUSED, const char *func,
> + Â Â Â Â Â Â Â Â Âsize_t linenr,
> Â Â Â Â Â Â Â Â Â const char *clienttty ATTRIBUTE_UNUSED,
> Â Â Â Â Â Â Â Â Â const char *clientaddr ATTRIBUTE_UNUSED,
> Â Â Â Â Â Â Â Â Â enum virAuditRecordType type ATTRIBUTE_UNUSED, bool
> success,
> Â Â Â Â Â Â Â Â Â const char *fmt, ...)
> -#endif
> Â{
> Â Â char *str = NULL;
> Â Â va_list args;
>
>

ACK.

Matthias

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]