]> jfr.im git - irc.git/blame - software/RELEASES/ircservices/achurch.org/services/lists/ircservices/2002/003349.html
init
[irc.git] / software / RELEASES / ircservices / achurch.org / services / lists / ircservices / 2002 / 003349.html
CommitLineData
3bd189cb
JR
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
2<HTML>
3 <HEAD>
4 <TITLE> [IRCServices] Feature request about nickname links and a sort of bug report
5 </TITLE>
6 <LINK REL="Index" HREF="index.html" >
7 <LINK REL="made" HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20Feature%20request%20about%20nickname%20links%20and%20a%20sort%20of%20bug%20report&In-Reply-To=">
8 <META NAME="robots" CONTENT="index,nofollow">
9 <META http-equiv="Content-Type" content="text/html; charset=us-ascii">
10 <LINK REL="Previous" HREF="003348.html">
11 <LINK REL="Next" HREF="003351.html">
12 </HEAD>
13 <BODY BGCOLOR="#ffffff">
14 <H1>[IRCServices] Feature request about nickname links and a sort of bug report</H1>
15 <B>Milko Krachounov</B>
16 <A HREF="mailto:ircservices%40ircservices.za.net?Subject=%5BIRCServices%5D%20Feature%20request%20about%20nickname%20links%20and%20a%20sort%20of%20bug%20report&In-Reply-To="
17 TITLE="[IRCServices] Feature request about nickname links and a sort of bug report">milko at milko.zon3x.net
18 </A><BR>
19 <I>Sun Nov 24 16:00:01 PST 2002</I>
20 <P><UL>
21 <LI>Previous message: <A HREF="003348.html">[IRCServices] option for /ns drop not to be so drastic ;)
22</A></li>
23 <LI>Next message: <A HREF="003351.html">[IRCServices] Feature request about nickname links and a sort of bug report
24</A></li>
25 <LI> <B>Messages sorted by:</B>
26 <a href="date.html#3349">[ date ]</a>
27 <a href="thread.html#3349">[ thread ]</a>
28 <a href="subject.html#3349">[ subject ]</a>
29 <a href="author.html#3349">[ author ]</a>
30 </LI>
31 </UL>
32 <HR>
33<!--beginarticle-->
34<PRE>Currently, with the new linking module you can link only unregistered nick
35to your nick. That's nice, but if there are people who have already
36registered their nicks and now want to link them without reseting their
37&quot;Time registered&quot; there is no way for them to do it. I run services in a
38small network and it's not a problem for me to export the database to XML,
39link the nicks by hand and then import the XML, but I think adding a little
40feature which does this thing would be nice...
41
42For example:
43/ns link nickname2
44This will link a non-registered nickname...
45/ns link nickname2 password
46If the nickname2 is registered (and this is the correct password for its
47nickgroup ;P) and it is main in its nick group all nicks, channels, memos
48will be moved from the nickname2's group to your group, if it is NOT the
49main nick in its group, only nickname2 will be moved to your group.
50
51/ns unlink nickname2 drops the linked nickname.
52/ns unlink nickname2 password creates a new nickgroup with nickname2 in
53it...
54
55............................
56
57I was the trying to write the above myself (it worked, but the server
58segfaulted 2-3 minutes after use of these feautres, even though after XML
59export of the database everything looked OK) and I noticed something that
60looks like a bug in the oldlink.c:
61
62/* Check for exceeding the per-email nick registration limit. */
63if (NSRegEmailMax &amp;&amp; target_ngi-&gt;email &amp;&amp; !is_services_admin(u)
64 &amp;&amp; abs(n=count_nicks_with_email(target_ngi-&gt;email)) &gt;= NSRegEmailMax
65 ) {
66 notice_lang(s_NickServ, u, NICK_LINK_TOO_MANY_NICKS, n,
67 NSRegEmailMax);
68 return;
69 }
70
71The above checks whether currently the nicknames registered with
72target_ngi's email haven't reached the maximum nicknames with the same email
73allowed, but this will work fine if ngi contains only ONE nick, if it
74contains more than one nick a user may be able to link a group with 30 nicks
75(currently with another email set), to another group with say 50 nicks, the
76result will be 80 nicks with the same email, even if the limit is set to
77something less than 80... I think it will work that way:
78
79if (NSRegEmailMax &amp;&amp; target_ngi-&gt;email &amp;&amp; !is_services_admin(u)
80 &amp;&amp; abs(n=count_nicks_with_email(target_ngi-&gt;email)) &gt;= NSRegEmailMax
81 &amp;&amp; irc_stricmp(ngi-&gt;email, target_ngi-&gt;email) == 0) {
82 notice_lang(s_NickServ, u, NICK_LINK_TOO_MANY_NICKS, n,
83 NSRegEmailMax);
84 return;
85 } else if (NSRegEmailMax &amp;&amp; target_ngi-&gt;email &amp;&amp; !is_services_admin(u)
86 &amp;&amp; abs(n=count_nicks_with_email(target_ngi-&gt;email))
87 + ngi-&gt;nicks_count &gt;= NSRegEmailMax
88 &amp;&amp; irc_stricmp(ngi-&gt;email, target_ngi-&gt;email) != 0) {
89 notice_lang(s_NickServ, u, NICK_LINK_TOO_MANY_NICKS, n,
90 NSRegEmailMax);
91 return;
92 }
93
94(I'm not very good in writing C sources, so I don't guarantee that the above
95will work :) )
96
97.....................
98
99I just notice request from Craig Edwards about the ability to DROP linked
100nick without droping the whole nickgroup... I think it is a good idea, but
101for the DROPNICK feature, as I may want to drop some of someone's linked
102nickname, but not his WHOLE nickname group...
103
104Sorry for puting all these things in same place...
105
106
107</PRE>
108
109<!--endarticle-->
110 <HR>
111 <P><UL>
112 <!--threads-->
113 <LI>Previous message: <A HREF="003348.html">[IRCServices] option for /ns drop not to be so drastic ;)
114</A></li>
115 <LI>Next message: <A HREF="003351.html">[IRCServices] Feature request about nickname links and a sort of bug report
116</A></li>
117 <LI> <B>Messages sorted by:</B>
118 <a href="date.html#3349">[ date ]</a>
119 <a href="thread.html#3349">[ thread ]</a>
120 <a href="subject.html#3349">[ subject ]</a>
121 <a href="author.html#3349">[ author ]</a>
122 </LI>
123 </UL>
124
125</body></html>