• Arnd Bergmann's avatar
    netfilter: ipvs: avoid unused variable warnings · f6ca9f46
    Arnd Bergmann authored
    The proc_create() and remove_proc_entry() functions do not reference
    their arguments when CONFIG_PROC_FS is disabled, so we get a couple
    of warnings about unused variables in IPVS:
    
    ipvs/ip_vs_app.c:608:14: warning: unused variable 'net' [-Wunused-variable]
    ipvs/ip_vs_ctl.c:3950:14: warning: unused variable 'net' [-Wunused-variable]
    ipvs/ip_vs_ctl.c:3994:14: warning: unused variable 'net' [-Wunused-variable]
    
    This removes the local variables and instead looks them up separately
    for each use, which obviously avoids the warning.
    Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
    Fixes: 4c50a8ce2b63 ("netfilter: ipvs: avoid unused variable warning")
    Acked-by: default avatarJulian Anastasov <ja@ssi.bg>
    Signed-off-by: default avatarSimon Horman <horms@verge.net.au>
    f6ca9f46
ip_vs_app.c 13.3 KB