diff --git a/contrib/ipfilter/tools/ippool.c b/contrib/ipfilter/tools/ippool.c index b0466b110af2..c8a9c70b136e 100644 --- a/contrib/ipfilter/tools/ippool.c +++ b/contrib/ipfilter/tools/ippool.c @@ -201,10 +201,14 @@ poolnodecommand(remove, argc, argv) } break; case 'T' : - ttl = atoi(optarg); - if (ttl < 0) { - fprintf(stderr, "cannot set negative ttl\n"); - return -1; + if (remove == 0) { + ttl = atoi(optarg); + if (ttl < 0) { + fprintf(stderr, "cannot set negative ttl\n"); + return -1; + } + } else { + usage(argv[0]); } break; case 'v' :