Skip to content

Commit

Permalink
Pull request 302: AG-27796 upd golibs
Browse files Browse the repository at this point in the history
Squashed commit of the following:

commit e8ef9c5
Merge: bb188da 5eb940d
Author: Eugene Burkov <[email protected]>
Date:   Mon Dec 4 16:55:44 2023 +0300

    Merge branch 'master' into AG-27796-upd-golibs

commit bb188da
Author: Eugene Burkov <[email protected]>
Date:   Mon Nov 27 14:31:30 2023 +0300

    all: upd golibs, imp docs

commit 9d52587
Author: Eugene Burkov <[email protected]>
Date:   Fri Nov 24 14:33:18 2023 +0300

    upstream: imp names

commit 10657f4
Author: Eugene Burkov <[email protected]>
Date:   Fri Nov 24 14:29:20 2023 +0300

    upstream: imp names, docs

commit 51fa582
Author: Eugene Burkov <[email protected]>
Date:   Fri Nov 24 14:21:17 2023 +0300

    all: upd golibs
  • Loading branch information
EugeneOne1 committed Dec 5, 2023
1 parent 5eb940d commit 0ebda58
Show file tree
Hide file tree
Showing 11 changed files with 51 additions and 367 deletions.
2 changes: 1 addition & 1 deletion go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/AdguardTeam/dnsproxy
go 1.20

require (
github.com/AdguardTeam/golibs v0.17.0
github.com/AdguardTeam/golibs v0.18.0
github.com/ameshkov/dnscrypt/v2 v2.2.7
github.com/ameshkov/dnsstamps v1.0.3
github.com/beefsack/go-rate v0.0.0-20220214233405-116f4ca011a0
Expand Down
6 changes: 4 additions & 2 deletions go.sum
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
github.com/AdguardTeam/golibs v0.17.0 h1:oPp2+2kV41qH45AIFbAlHFTPQOQ6JbF+JemjeECFn1g=
github.com/AdguardTeam/golibs v0.17.0/go.mod h1:DKhCIXHcUYtBhU8ibTLKh1paUL96n5zhQBlx763sj+U=
github.com/AdguardTeam/golibs v0.17.3 h1:V3XWPh2OirWuz0lgvcrpq7Hz3qcb0j6gq5+oPSxe2/Y=
github.com/AdguardTeam/golibs v0.17.3/go.mod h1:DKhCIXHcUYtBhU8ibTLKh1paUL96n5zhQBlx763sj+U=
github.com/AdguardTeam/golibs v0.18.0 h1:ckS2YK7t2Ub6UkXl0fnreVaM15Zb07Hh1gmFqttjpWg=
github.com/AdguardTeam/golibs v0.18.0/go.mod h1:DKhCIXHcUYtBhU8ibTLKh1paUL96n5zhQBlx763sj+U=
github.com/aead/chacha20 v0.0.0-20180709150244-8b13a72661da h1:KjTM2ks9d14ZYCvmHS9iAKVt9AyzRSqNU1qabPih5BY=
github.com/aead/chacha20 v0.0.0-20180709150244-8b13a72661da/go.mod h1:eHEWzANqSiWQsof+nXEI9bUVUyV6F53Fp89EuCh2EAA=
github.com/aead/poly1305 v0.0.0-20180717145839-3fee0db0b635 h1:52m0LGchQBBVqJRyYYufQuIbVqRawmubW3OFGqK1ekw=
Expand Down
155 changes: 0 additions & 155 deletions internal/netutil/hosts.go

This file was deleted.

119 changes: 0 additions & 119 deletions internal/netutil/hosts_test.go

This file was deleted.

14 changes: 0 additions & 14 deletions internal/osutil/osutil.go

This file was deleted.

12 changes: 0 additions & 12 deletions internal/osutil/osutil_unix.go

This file was deleted.

25 changes: 0 additions & 25 deletions internal/osutil/osutil_windows.go

This file was deleted.

5 changes: 2 additions & 3 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -15,14 +15,13 @@ import (
"syscall"
"time"

"github.com/AdguardTeam/dnsproxy/internal/bootstrap"
proxynetutil "github.com/AdguardTeam/dnsproxy/internal/netutil"
"github.com/AdguardTeam/dnsproxy/internal/osutil"
"github.com/AdguardTeam/dnsproxy/internal/version"
"github.com/AdguardTeam/dnsproxy/proxy"
"github.com/AdguardTeam/dnsproxy/upstream"
"github.com/AdguardTeam/golibs/log"
"github.com/AdguardTeam/golibs/mathutil"
"github.com/AdguardTeam/golibs/osutil"
"github.com/AdguardTeam/golibs/timeutil"
"github.com/ameshkov/dnscrypt/v2"
goFlags "github.com/jessevdk/go-flags"
Expand Down Expand Up @@ -477,7 +476,7 @@ func initBootstrap(bootstraps []string, opts *upstream.Options) (r upstream.Reso

switch len(resolvers) {
case 0:
etcHosts, hostsErr := bootstrap.NewDefaultHostsResolver(osutil.RootDirFS())
etcHosts, hostsErr := upstream.NewDefaultHostsResolver(osutil.RootDirFS())
if hostsErr != nil {
log.Error("creating default hosts resolver: %s", hostsErr)

Expand Down
2 changes: 0 additions & 2 deletions scripts/make/go-lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -173,7 +173,6 @@ run_linter govulncheck ./...
run_linter gocyclo --over 10\
./internal/bootstrap/\
./internal/netutil/\
./internal/osutil/\
./internal/version/\
./proxyutil/\
./upstream/\
Expand All @@ -186,7 +185,6 @@ run_linter gocyclo --over 15 ./proxy/
# TODO(a.garipov): Enable for all.
run_linter gocognit --over 10\
./internal/bootstrap/\
./internal/osutil/\
./internal/version/\
./proxyutil/\
./upstream/\
Expand Down
Loading

0 comments on commit 0ebda58

Please sign in to comment.