added basic ssl support to ircu
[ircu2.10.12-pk.git] / ircd / m_defaults.c
index 67fcc1b5a0342fa0540b8f5e3a44c221be7f5875..9a85c82e038287010e1eedddecdb977af8dc1bf2 100644 (file)
  *
  * $Id$
  */
-#if 0
-/*
- * No need to include handlers.h here the signatures must match
- * and we don't need to force a rebuild of all the handlers everytime
- * we add a new one to the list. --Bleep
- */
-#include "handlers.h"
-#endif /* 0 */
+#include "config.h"
+
 #include "client.h"
 #include "ircd.h"
+#include "ircd_log.h"
 #include "ircd_reply.h"
 #include "numeric.h"
 #include "numnicks.h"
@@ -39,7 +34,7 @@
 #include "supported.h"
 #include "version.h"
 
-#include <assert.h>
+/* #include <assert.h> -- Now using assert in ircd_log.h */
 
 /*
  * m_functions execute protocol messages on this server:
 
 int m_not_oper(struct Client* cptr, struct Client* sptr, int parc, char* parv[])
 {
-  return send_error_to_client(cptr, ERR_NOPRIVILEGES);
+  return send_reply(cptr, ERR_NOPRIVILEGES);
 }
 
 int m_unregistered(struct Client* cptr, struct Client* sptr, int parc, char* parv[])
 {
-  sendto_one(cptr, ":%s %d * %s :Register first.",
-             me.name, ERR_NOTREGISTERED, parv[0]);
+  send_reply(cptr, SND_EXPLICIT | ERR_NOTREGISTERED, "%s :Register first.",
+            parv[0]);
   return 0;
 }
 
 int m_registered(struct Client* cptr, struct Client* sptr, int parc, char* parv[])
 {
-  return send_error_to_client(sptr, ERR_ALREADYREGISTRED);
+  return send_reply(sptr, ERR_ALREADYREGISTRED);
 }
 
 int m_ignore(struct Client* cptr, struct Client* sptr, int parc, char* parv[])
@@ -122,9 +117,5 @@ int m_ignore(struct Client* cptr, struct Client* sptr, int parc, char* parv[])
 
 int m_unsupported(struct Client* cptr, struct Client* sptr, int parc, char* parv[])
 {
-#if 0
-  sendto_one(cptr, ":%s %d * %s :Unsupported command",
-             me.name, ERR_UNSUPPORTED, parv[0]);
-#endif
   return 0;
 }