Re: [PATCH 2/2] nwfilter: enum cleanups in "src/nwfilter/*"

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

 



On 06/24/2014 01:02 PM, Eric Blake wrote:
> On 06/15/2014 10:32 AM, Julio Faracco wrote:
>> As we are doing with the enum structures, a cleanup in
>> "src/nwfilter/" directory was done now. All the enums that were
>> defined in the header files were converted to typedefs in this
>> directory. This patch includes all the adjustments to remove
>> conflicts when you do this kind of change. "Enum-to-typedef"'s
>> conversions were made in "src/nwfilter/nwfilter_{gentech_driver,
>> learnipaddr, tech_driver}.h".
>>
>> Signed-off-by: Julio Faracco <jcfaracco@xxxxxxxxx>
>> ---
>>  src/nwfilter/nwfilter_gentech_driver.c |   12 ++++++------
>>  src/nwfilter/nwfilter_gentech_driver.h |    4 ++--
>>  src/nwfilter/nwfilter_learnipaddr.c    |    2 +-
>>  src/nwfilter/nwfilter_learnipaddr.h    |    8 ++++----
>>  src/nwfilter/nwfilter_tech_driver.h    |    6 +++---
>>  5 files changed, 16 insertions(+), 16 deletions(-)
>>

>>  
>> -enum techDrvFlags {
>> +typedef enum {
>>      TECHDRV_FLAG_INITIALIZED = (1 << 0),
>> -};
>> +} techDrvFlags;
> 
> Also this enum.
> 
> At any rate, your patch is a strict improvement, so ACK and pushed.

I spoke too soon.  Your patch failed to build:

  CC       nwfilter/libvirt_driver_nwfilter_impl_la-nwfilter_learnipaddr.lo
nwfilter/nwfilter_learnipaddr.c:329:19: error: 'enum howDetect' declared
inside parameter list [-Werror]
              enum howDetect *howDetected)
                   ^
nwfilter/nwfilter_learnipaddr.c:329:19: error: its scope is only this
definition or declaration, which is probably not what you want [-Werror]
nwfilter/nwfilter_learnipaddr.c: In function 'procDHCPOpts':
nwfilter/nwfilter_learnipaddr.c:353:21: error: dereferencing pointer to
incomplete type
                     *howDetected = DETECT_DHCP;
                     ^
nwfilter/nwfilter_learnipaddr.c: In function 'learnIPAddressThread':
nwfilter/nwfilter_learnipaddr.c:398:10: error: variable 'howDetected'
has initializer but incomplete type
     enum howDetect howDetected = 0;
          ^

Please respin the patch, and when posting v2, it would be nice to
include the renames into the right namespace prefix.

-- 
Eric Blake   eblake redhat com    +1-919-301-3266
Libvirt virtualization library http://libvirt.org

Attachment: signature.asc
Description: OpenPGP digital signature

--
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]