Browse Source

m_listrestrict/topicgreeting: Unreal 4.2.1 changes handling of max topic length, so added compatibility =]

Wazakindjes 2 months ago
parent
commit
c308abf4b4
2 changed files with 10 additions and 2 deletions
  1. 5 1
      spec/m_topicgreeting.c
  2. 5 1
      u4/m_listrestrict.c

+ 5 - 1
spec/m_topicgreeting.c

@@ -7,6 +7,10 @@
 // One include for all cross-platform compatibility thangs
 #include "unrealircd.h"
 
+#ifndef TOPICLEN
+	#define TOPICLEN iConf.topic_length
+#endif
+
 #define MYHEWK HOOKTYPE_LOCAL_JOIN
 #define CHMODE_FLAG 'g' // As in greet obv =]
 
@@ -24,7 +28,7 @@ Hook *tgreetingJoinHook = NULL;
 // Dat dere module header
 ModuleHeader MOD_HEADER(m_topicgreeting) = {
 	"m_topicgreeting", // Module name
-	"$Id: v1.0 2018/08/25 Gottem$", // Version
+	"$Id: v1.01 2019/02/02 Gottem$", // Version
 	"Greet users who join a channel by changing the topic (channel mode +g)", // Description
 	"3.2-b8-1", // Modversion, not sure wat do
 	NULL

+ 5 - 1
u4/m_listrestrict.c

@@ -9,6 +9,10 @@
 // One include for all cross-platform compatibility thangs
 #include "unrealircd.h"
 
+#ifndef TOPICLEN
+	#define TOPICLEN iConf.topic_length
+#endif
+
 #define MYCONF "listrestrict"
 #define OVR_LIST "LIST"
 #define OVR_JOIN "JOIN"
@@ -70,7 +74,7 @@ time_t glineTime = 86400; // Default to 1 day
 // Dat dere module header
 ModuleHeader MOD_HEADER(m_listrestrict) = {
 	"m_listrestrict", // Module name
-	"$Id: v1.03 2018/11/04 Gottem/k4be$", // Version
+	"$Id: v1.04 2019/02/02 Gottem/k4be$", // Version
 	"Impose certain restrictions on /LIST usage", // Description
 	"3.2-b8-1", // Modversion, not sure wat do
 	NULL