View | Details | Raw Unified | Return to bug 189618 | Differences between
and this patch

Collapse All | Expand All

(-)files/geoipupdate.sh.in (-1 / +13 lines)
Lines 1-2 Link Here
1
#!/bin/sh
1
#!/bin/sh
2
fetch -o - http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz | gunzip > %%DATADIR%%/GeoIP.dat
2
TEMPFILE=`mktemp %%DATADIR%%/GeoIP.dat-XXXXXX`
3
if fetch -o - http://geolite.maxmind.com/download/geoip/database/GeoLiteCountry/GeoIP.dat.gz | gunzip >> $TEMPFILE ; then
4
    chmod og+r $TEMPFILE
5
    if ! mv $TEMPFILE %%DATADIR%%/GeoIP.dat ; then
6
        rm $TEMPFILE
7
        echo fail to substitute GeoIP.dat 
8
        exit 2
9
    fi
10
else
11
    rm $TEMPFILE
12
    echo fail to update GeoIP.dat
13
    exit 1
14
fi

Return to bug 189618