summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvgeny Zinoviev <me@ch1p.io>2022-01-11 21:35:07 +0300
committerEvgeny Zinoviev <me@ch1p.io>2022-01-11 21:35:07 +0300
commite2164c15e356c9dfae0d94fc75200ef81f8c84cc (patch)
tree0b5a132bb9b0892e801d9a492eea75ed8b8e521c
parent284d151d65e0ea43e5a41ab0d409f6549cde464b (diff)
fixes
-rwxr-xr-xcf-ipset.sh5
1 files changed, 1 insertions, 4 deletions
diff --git a/cf-ipset.sh b/cf-ipset.sh
index 29bfa66..082f9bb 100755
--- a/cf-ipset.sh
+++ b/cf-ipset.sh
@@ -1,18 +1,15 @@
#!/bin/bash
-TEMP=$(mktemp)
-IPSET_NAME="$1"
-
ipset_exists() {
ipset -L "$1" >/dev/null 2>/dev/null
}
die() {
echo "error: $@"
- [ -f "$TEMP" ] && rm "$TEMP"
exit 1
}
+IPSET_NAME="$1"
[ -z "$IPSET_NAME" ] && {
echo "usage: $0 IPSET_NAME"
exit