summary refs log tree commit diff
path: root/handle.c
diff options
context:
space:
mode:
authorNakidai <nakidai@disroot.org>2026-02-01 20:04:41 +0300
committerNakidai <nakidai@disroot.org>2026-02-01 20:04:41 +0300
commite50f850d763e3b1e6b06b4b312512a5b006eabbc (patch)
tree8f40752a756182fff9615187b3f482c73b77fdef /handle.c
parentac52bbe3427cda3bd2098ee35e06163885b21836 (diff)
downloadlibreircd-e50f850d763e3b1e6b06b4b312512a5b006eabbc.tar.gz
libreircd-e50f850d763e3b1e6b06b4b312512a5b006eabbc.zip
Fix all the warnings
The one in user.c is the funniest one
Diffstat (limited to 'handle.c')
-rw-r--r--handle.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/handle.c b/handle.c
index 698e8a9..e84f098 100644
--- a/handle.c
+++ b/handle.c
@@ -169,6 +169,8 @@ ping(struct Message *msg, struct Peer *peer)
 static int
 pong(struct Message *msg, struct Peer *peer)
 {
+	ensure(msg->params[0] && *msg->params[0], reply(peer, 409), 0);
+
 	peer->ping = 0;
 
 	return 0;
@@ -246,8 +248,6 @@ privmsg(struct Message *msg, struct Peer *peer)
 static int
 quit(struct Message *msg, struct Peer *peer)
 {
-	ensure(peer->type, (void)0, 1)
-
 	strlcpy(peer->quit, msg->params[0] ? msg->params[0] : "Client Quit", PEER_QUIT_MAX);
 
 	return 1;