ipset: github disabled gzip support

This commit is contained in:
bol-van
2024-06-19 09:03:15 +03:00
parent dcae31fae8
commit eebe68ca65
6 changed files with 17 additions and 9 deletions

View File

@@ -103,12 +103,20 @@ zzexist()
{
[ -f "$1.gz" ] || [ -f "$1" ]
}
zztest()
{
gzip -t "$1" 2>/dev/null
}
zzcat()
{
if [ -f "$1.gz" ]; then
gunzip -c "$1.gz"
elif [ -f "$1" ]; then
cat "$1"
if zztest "$1"; then
gunzip -c "$1"
else
cat "$1"
fi
fi
}
zz()