From b2189641f581d7a63747ec0b214713bc4d50a799 Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Mon, 8 Aug 2022 13:11:36 +0000 Subject: [PATCH] fix(deps): update module github.com/ip2location/ip2location-go/v9 to v9.4.1 --- go.mod | 2 +- go.sum | 2 ++ .../github.com/ip2location/ip2location-go/v9/ip2location.go | 5 ++--- vendor/modules.txt | 2 +- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/go.mod b/go.mod index ae1d764..a1dec31 100644 --- a/go.mod +++ b/go.mod @@ -2,4 +2,4 @@ module github.com/nscuro/traefik-plugin-geoblock go 1.17 -require github.com/ip2location/ip2location-go/v9 v9.4.0 +require github.com/ip2location/ip2location-go/v9 v9.4.1 diff --git a/go.sum b/go.sum index 9b0dad0..e29989c 100644 --- a/go.sum +++ b/go.sum @@ -4,3 +4,5 @@ github.com/ip2location/ip2location-go/v9 v9.3.0 h1:qfgr4ppf21ZyrOrmh4/db4SamL9hj github.com/ip2location/ip2location-go/v9 v9.3.0/go.mod h1:s5SV6YZL10TpfPpXw//7fEJC65G/yH7Oh+Tjq9JcQEQ= github.com/ip2location/ip2location-go/v9 v9.4.0 h1:VV+clcfWo+BCi37+1zVOLCoyy01GT18/RTtAeIR5EP0= github.com/ip2location/ip2location-go/v9 v9.4.0/go.mod h1:s5SV6YZL10TpfPpXw//7fEJC65G/yH7Oh+Tjq9JcQEQ= +github.com/ip2location/ip2location-go/v9 v9.4.1 h1:Gf7KoyyIVnltwvd7TcwKrkJC9ZnYqiyndXEJtT07AyI= +github.com/ip2location/ip2location-go/v9 v9.4.1/go.mod h1:s5SV6YZL10TpfPpXw//7fEJC65G/yH7Oh+Tjq9JcQEQ= diff --git a/vendor/github.com/ip2location/ip2location-go/v9/ip2location.go b/vendor/github.com/ip2location/ip2location-go/v9/ip2location.go index c7f2c6a..1da2198 100644 --- a/vendor/github.com/ip2location/ip2location-go/v9/ip2location.go +++ b/vendor/github.com/ip2location/ip2location-go/v9/ip2location.go @@ -144,7 +144,7 @@ var usagetype_position = [26]uint8{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, var addresstype_position = [26]uint8{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 21} var category_position = [26]uint8{0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 22} -const api_version string = "9.4.0" +const api_version string = "9.4.1" var max_ipv4_range = big.NewInt(4294967295) var max_ipv6_range = big.NewInt(0) @@ -327,7 +327,7 @@ func (d *DB) readstr(pos uint32) (string, error) { var retval string data := make([]byte, readlen) _, err := d.f.ReadAt(data, pos2) - if err != nil { + if err != nil && err.Error() != "EOF" { // bypass EOF error coz we are reading 256 which may hit EOF return "", err } strlen := data[0] @@ -902,7 +902,6 @@ func (d *DB) query(ipaddress string, mode uint32) (IP2Locationrecord, error) { ipto32 := d.readuint32_row(fullrow, colsize) ipto = big.NewInt(int64(ipto32)) - } else { ipfrom = d.readuint128_row(fullrow, 0) diff --git a/vendor/modules.txt b/vendor/modules.txt index c10ccbd..c3cc52a 100644 --- a/vendor/modules.txt +++ b/vendor/modules.txt @@ -1,3 +1,3 @@ -# github.com/ip2location/ip2location-go/v9 v9.4.0 +# github.com/ip2location/ip2location-go/v9 v9.4.1 ## explicit; go 1.14 github.com/ip2location/ip2location-go/v9