Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
G
Geth-Modification
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
张蕾
Geth-Modification
Commits
b3834d82
Commit
b3834d82
authored
10 years ago
by
obscuren
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Removed extra slash so @nicksavers gets off my back ;-)
parent
a26c4791
master
v1.10.12
v1.10.12-modified
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
9 deletions
+11
-9
client_identity.go
ethwire/client_identity.go
+11
-9
No files found.
ethwire/client_identity.go
View file @
b3834d82
...
...
@@ -11,7 +11,6 @@ type ClientIdentity interface {
}
type
SimpleClientIdentity
struct
{
clientString
string
clientIdentifier
string
version
string
customIdentifier
string
...
...
@@ -27,26 +26,29 @@ func NewSimpleClientIdentity(clientIdentifier string, version string, customIden
os
:
runtime
.
GOOS
,
implementation
:
"Go"
,
}
clientIdentity
.
init
()
return
clientIdentity
}
func
(
c
*
SimpleClientIdentity
)
init
()
{
c
.
clientString
=
fmt
.
Sprintf
(
"%s/v%s/%s/%s/%s"
,
}
func
(
c
*
SimpleClientIdentity
)
String
()
string
{
var
id
string
if
len
(
c
.
customIdentifier
)
>
0
{
id
=
"/"
+
c
.
customIdentifier
}
return
fmt
.
Sprintf
(
"%s/v%s%s/%s/%s"
,
c
.
clientIdentifier
,
c
.
version
,
c
.
customIdentifier
,
id
,
c
.
os
,
c
.
implementation
)
}
func
(
c
*
SimpleClientIdentity
)
String
()
string
{
return
c
.
clientString
}
func
(
c
*
SimpleClientIdentity
)
SetCustomIdentifier
(
customIdentifier
string
)
{
c
.
customIdentifier
=
customIdentifier
c
.
init
()
}
func
(
c
*
SimpleClientIdentity
)
GetCustomIdentifier
()
string
{
...
...
This diff is collapsed.
Click to expand it.
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment