141edb306SCy Schubert 241edb306SCy Schubert /* 341edb306SCy Schubert * Copyright (C) 2012 by Darren Reed. 441edb306SCy Schubert * 541edb306SCy Schubert * See the IPFILTER.LICENCE file for details on licencing. 641edb306SCy Schubert * 741edb306SCy Schubert * $Id$ 841edb306SCy Schubert */ 941edb306SCy Schubert 1041edb306SCy Schubert #include "ipf.h" 1141edb306SCy Schubert 1241edb306SCy Schubert void printtunable(ipftune_t * tup)13*efeb8bffSCy Schubertprinttunable(ipftune_t *tup) 1441edb306SCy Schubert { 1541edb306SCy Schubert PRINTF("%s\tmin %lu\tmax %lu\tcurrent ", 1641edb306SCy Schubert tup->ipft_name, tup->ipft_min, tup->ipft_max); 1741edb306SCy Schubert if (tup->ipft_sz == sizeof(u_long)) 1841edb306SCy Schubert PRINTF("%lu\n", tup->ipft_vlong); 1941edb306SCy Schubert else if (tup->ipft_sz == sizeof(u_int)) 2041edb306SCy Schubert PRINTF("%u\n", tup->ipft_vint); 2141edb306SCy Schubert else if (tup->ipft_sz == sizeof(u_short)) 2241edb306SCy Schubert PRINTF("%hu\n", tup->ipft_vshort); 2341edb306SCy Schubert else if (tup->ipft_sz == sizeof(u_char)) 2441edb306SCy Schubert PRINTF("%u\n", (u_int)tup->ipft_vchar); 2541edb306SCy Schubert else { 2641edb306SCy Schubert PRINTF("sz = %d\n", tup->ipft_sz); 2741edb306SCy Schubert } 2841edb306SCy Schubert } 29