This is an automated email from the ASF dual-hosted git repository.
liuhan pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/skywalking-rover.git
The following commit(s) were added to refs/heads/main by this push:
new e736067 chore: correct var name (#72)
e736067 is described below
commit e7360677ba1022f84fe31c810eab7c8325be7f88
Author: 罗泽轩 <[email protected]>
AuthorDate: Mon Jan 16 11:14:04 2023 +0800
chore: correct var name (#72)
---
pkg/profiling/task/network/ssl.go | 14 +++++++-------
1 file changed, 7 insertions(+), 7 deletions(-)
diff --git a/pkg/profiling/task/network/ssl.go
b/pkg/profiling/task/network/ssl.go
index f6925f7..85bd470 100644
--- a/pkg/profiling/task/network/ssl.go
+++ b/pkg/profiling/task/network/ssl.go
@@ -535,19 +535,19 @@ func buildSSLSymAddrConfig(libcryptoPath string)
(*OpenSSLFdSymAddrConfigInBPF,
continue
}
major := submatch[1]
- mijor := submatch[2]
+ minor := submatch[2]
fix := submatch[3]
- log.Debugf("found the libcrypto.so version: %s.%s.%s", major,
mijor, fix)
+ log.Debugf("found the libcrypto.so version: %s.%s.%s", major,
minor, fix)
conf := &OpenSSLFdSymAddrConfigInBPF{}
// must be number, already validate in the regex
- mijorVal, _ := strconv.Atoi(mijor)
+ minorVal, _ := strconv.Atoi(minor)
fixVal, _ := strconv.Atoi(fix)
// max support version is 1.1.1
- if mijorVal > 1 || fixVal > 1 {
- return nil, fmt.Errorf("the fix version of the
libcrypto is not support: %s.%s.%s", major, mijor, fix)
+ if minorVal > 1 || fixVal > 1 {
+ return nil, fmt.Errorf("the version of the libcrypto is
not support: %s.%s.%s", major, minor, fix)
}
// bio offset
@@ -556,7 +556,7 @@ func buildSSLSymAddrConfig(libcryptoPath string)
(*OpenSSLFdSymAddrConfigInBPF,
conf.BIOReadOffset = 16
conf.BIOWriteOffset = 24
// fd offset
- if (mijorVal == 0) || (mijorVal == 1 && fixVal == 0) {
+ if (minorVal == 0) || (minorVal == 1 && fixVal == 0) {
// 1.0.x || 1.1.0
//
https://github.com/openssl/openssl/blob/OpenSSL_1_0_0-stable/crypto/bio/bio.h#L297-L306
conf.FDOffset = 40
@@ -566,7 +566,7 @@ func buildSSLSymAddrConfig(libcryptoPath string)
(*OpenSSLFdSymAddrConfigInBPF,
conf.FDOffset = 48
}
log.Debugf("the lobcrypto.so library symbol verson config,
version: %s.%s.%s, bio offset: %d",
- major, mijor, fix, conf.FDOffset)
+ major, minor, fix, conf.FDOffset)
return conf, nil
}
return nil, fmt.Errorf("could not fount the version of the
libcrypto.so")