Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
ecki
unix socket satyr
Commits
022efacb
Commit
022efacb
authored
Aug 26, 2022
by
ecki
Browse files
függvények kiegészítve
parent
3df6155d
Changes
1
Hide whitespace changes
Inline
Side-by-side
server.go
View file @
022efacb
...
...
@@ -22,19 +22,27 @@ func (t *ControlInterface) LoggedIntoCtr(args int, reply *int) error {
if
err
!=
nil
{
return
err
}
fmt
.
Println
(
args
,
"logged in"
,
u
.
Username
)
fmt
.
Println
(
u
.
Username
,
"logged in
to
"
,
args
)
*
reply
=
0
return
nil
}
func
(
t
*
ControlInterface
)
ExitedCtr
(
args
int
,
reply
*
int
)
error
{
fmt
.
Println
(
args
,
"Exited"
)
u
,
err
:=
user
.
LookupId
(
fmt
.
Sprint
(
t
.
Creds
.
Uid
))
if
err
!=
nil
{
return
err
}
fmt
.
Println
(
u
.
Username
,
"Exited"
,
args
)
*
reply
=
0
return
nil
}
func
(
t
*
ControlInterface
)
UsingTooMuchRes
(
args
int
,
reply
*
int
)
error
{
fmt
.
Println
(
args
,
"bad boy"
)
u
,
err
:=
user
.
LookupId
(
fmt
.
Sprint
(
t
.
Creds
.
Uid
))
if
err
!=
nil
{
return
err
}
fmt
.
Println
(
u
.
Username
,
"bad boy"
,
args
)
*
reply
=
0
return
nil
}
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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