mirror of
https://github.com/rwinkhart/peercred-mini.git
synced 2026-08-28 04:46:43 -04:00
Remove osGet
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
module github.com/rwinkhart/peercred-mini
|
||||
|
||||
go 1.24.1
|
||||
go 1.24.2
|
||||
|
||||
require github.com/rwinkhart/sys v0.0.0-20250404053244-7215932ae926
|
||||
|
||||
+1
-5
@@ -27,12 +27,8 @@ func (c *Creds) UserID() (uid string) {
|
||||
return c.uid
|
||||
}
|
||||
|
||||
func osGet(c net.Conn) (*Creds, error) {
|
||||
return getUnix(c.(*net.UnixConn))
|
||||
}
|
||||
|
||||
// Get returns the peer credentials for c.
|
||||
func Get(c net.Conn) *Creds {
|
||||
creds, _ := osGet(c)
|
||||
creds, _ := getUnix(c.(*net.UnixConn))
|
||||
return creds
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user