]>
Commit | Line | Data |
---|---|---|
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 | |
35 | to your nick. That's nice, but if there are people who have already | |
36 | registered their nicks and now want to link them without reseting their | |
37 | "Time registered" there is no way for them to do it. I run services in a | |
38 | small network and it's not a problem for me to export the database to XML, | |
39 | link the nicks by hand and then import the XML, but I think adding a little | |
40 | feature which does this thing would be nice... | |
41 | ||
42 | For example: | |
43 | /ns link nickname2 | |
44 | This will link a non-registered nickname... | |
45 | /ns link nickname2 password | |
46 | If the nickname2 is registered (and this is the correct password for its | |
47 | nickgroup ;P) and it is main in its nick group all nicks, channels, memos | |
48 | will be moved from the nickname2's group to your group, if it is NOT the | |
49 | main 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 | |
53 | it... | |
54 | ||
55 | ............................ | |
56 | ||
57 | I was the trying to write the above myself (it worked, but the server | |
58 | segfaulted 2-3 minutes after use of these feautres, even though after XML | |
59 | export of the database everything looked OK) and I noticed something that | |
60 | looks like a bug in the oldlink.c: | |
61 | ||
62 | /* Check for exceeding the per-email nick registration limit. */ | |
63 | if (NSRegEmailMax && target_ngi->email && !is_services_admin(u) | |
64 | && abs(n=count_nicks_with_email(target_ngi->email)) >= NSRegEmailMax | |
65 | ) { | |
66 | notice_lang(s_NickServ, u, NICK_LINK_TOO_MANY_NICKS, n, | |
67 | NSRegEmailMax); | |
68 | return; | |
69 | } | |
70 | ||
71 | The above checks whether currently the nicknames registered with | |
72 | target_ngi's email haven't reached the maximum nicknames with the same email | |
73 | allowed, but this will work fine if ngi contains only ONE nick, if it | |
74 | contains 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 | |
76 | result will be 80 nicks with the same email, even if the limit is set to | |
77 | something less than 80... I think it will work that way: | |
78 | ||
79 | if (NSRegEmailMax && target_ngi->email && !is_services_admin(u) | |
80 | && abs(n=count_nicks_with_email(target_ngi->email)) >= NSRegEmailMax | |
81 | && irc_stricmp(ngi->email, target_ngi->email) == 0) { | |
82 | notice_lang(s_NickServ, u, NICK_LINK_TOO_MANY_NICKS, n, | |
83 | NSRegEmailMax); | |
84 | return; | |
85 | } else if (NSRegEmailMax && target_ngi->email && !is_services_admin(u) | |
86 | && abs(n=count_nicks_with_email(target_ngi->email)) | |
87 | + ngi->nicks_count >= NSRegEmailMax | |
88 | && irc_stricmp(ngi->email, target_ngi->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 | |
95 | will work :) ) | |
96 | ||
97 | ..................... | |
98 | ||
99 | I just notice request from Craig Edwards about the ability to DROP linked | |
100 | nick without droping the whole nickgroup... I think it is a good idea, but | |
101 | for the DROPNICK feature, as I may want to drop some of someone's linked | |
102 | nickname, but not his WHOLE nickname group... | |
103 | ||
104 | Sorry 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> |