[Tkabber-dev] r325 - trunk/plugins/bldjid

tkabber-svn at jabber.ru tkabber-svn at jabber.ru
Fri Mar 26 07:23:46 MSK 2010


Author: bigote
Date: 2010-03-26 07:23:46 +0300 (Fri, 26 Mar 2010)
New Revision: 325

Modified:
   trunk/plugins/bldjid/ChangeLog
   trunk/plugins/bldjid/README
   trunk/plugins/bldjid/README.ru
   trunk/plugins/bldjid/TODO
   trunk/plugins/bldjid/bldjid.tcl
Log:
Timeout for version requests augmented to 120 seconds (90-sec timeout fails quite often when requesting mobile client versions).
Fixed a bug that provoked strange false alarms when watching jid entrances in rooms where we don't have admin privileges.


Modified: trunk/plugins/bldjid/ChangeLog
===================================================================
--- trunk/plugins/bldjid/ChangeLog	2010-03-24 18:19:19 UTC (rev 324)
+++ trunk/plugins/bldjid/ChangeLog	2010-03-26 04:23:46 UTC (rev 325)
@@ -1,3 +1,16 @@
+2010-03-26  Serge Yudin  <xmpp:bigote at jabber.ru> <mailto:bigote at gmail.com>
+
+--- Version 0.9.9.1 of the plugin.
+
+--- Files modified:
+    bldjid.tcl, ChangeLog, README, README.ru, msgs/ru.msg, TODO.
+
+--- Changes:
+	Timeout for version requests augmented to 120 seconds (90-sec timeout
+	fails quite often when requesting mobile client versions).
+	Fixed a bug that provoked strange false alarms when watching jid
+	entrances in rooms where we don't have admin privileges.
+
 2010-03-24  Serge Yudin  <xmpp:bigote at jabber.ru> <mailto:bigote at gmail.com>
 
 --- Version 0.9.9 of the plugin.

Modified: trunk/plugins/bldjid/README
===================================================================
--- trunk/plugins/bldjid/README	2010-03-24 18:19:19 UTC (rev 324)
+++ trunk/plugins/bldjid/README	2010-03-26 04:23:46 UTC (rev 325)
@@ -211,7 +211,7 @@
 	we just leave the array as is and finally add the entry to the file
 	with "Timeout" version to be aware of this user. If you see too many users
 	with "Timeout" version you probably should increase the timeout wich is
-	90 seconds by default.
+	120 seconds by default.
 
 --- ::plugins::bldjid::options(verbosity_level)
 -	Minimum level means that there will be no repeated JIDs in each room list.

Modified: trunk/plugins/bldjid/README.ru
===================================================================
--- trunk/plugins/bldjid/README.ru	2010-03-24 18:19:19 UTC (rev 324)
+++ trunk/plugins/bldjid/README.ru	2010-03-26 04:23:46 UTC (rev 325)
@@ -216,7 +216,7 @@
 	мы оставляем массив как есть и добавляем эту запись в файл, оставив в качестве
 	версии слово "Timeout", чтобы быть в курсе. Если вы наблюдаете слишком много
 	пользователей с версией "Timeout", вам следует увеличить тайм-аут,
-	который по умолчанию равен 90 секундам.
+	который по умолчанию равен 120 секундам.
 
 --- ::plugins::bldjid::options(verbosity_level)
 -	Минимальный уровень "надоедливости" означает, что в лог будет попадать

Modified: trunk/plugins/bldjid/TODO
===================================================================
--- trunk/plugins/bldjid/TODO	2010-03-24 18:19:19 UTC (rev 324)
+++ trunk/plugins/bldjid/TODO	2010-03-26 04:23:46 UTC (rev 325)
@@ -27,10 +27,6 @@
 
 ===	Enhance search engine by adding another "ver" search parameter.
 
-===	Add notifying of a certain jid(s) entrance. Its behaviour should be similar
-	to Spy plugins' but the difference is that we will watch silently here
-	and will only notify about visitors entering rooms, not about roster contacts.
-
 ===	Fix a bug with broken monitor window if editing window size is changed.
 
 ===	Add "Antiflood & Autokick" functionality.

Modified: trunk/plugins/bldjid/bldjid.tcl
===================================================================
--- trunk/plugins/bldjid/bldjid.tcl	2010-03-24 18:19:19 UTC (rev 324)
+++ trunk/plugins/bldjid/bldjid.tcl	2010-03-26 04:23:46 UTC (rev 325)
@@ -1,4 +1,4 @@
-# "Bldjid" plugin for Tkabber. 2010-03-24 v. 0.9.9
+# "Bldjid" plugin for Tkabber. 2010-03-26 v. 0.9.9.1
 # Written by Serge Yudin xmpp:bigote at jabber.ru
 # See README or README.ru file for usage.
 
@@ -66,7 +66,7 @@
 			[::msgcat::mc "Enable this option to log visitors' client version and OS."] \
 			-type boolean -group Bldjid
 
-		custom::defvar options(ver_timeout) 90 \
+		custom::defvar options(ver_timeout) 120 \
 			[::msgcat::mc "Timeout for version requests (in seconds).\
 			See README for details."] \
 			-type integer -group Bldjid
@@ -197,8 +197,11 @@
 			if {$options(strip_resource)} {
 				set real_jid $bare_jid
 			}
+			set iam [whoami $xlib $group]
 			if {[info exists watched_jids] \
-			&&  [string match -nocase *$bare_jid* $watched_jids]} {
+			&&  [string match -nocase *$bare_jid* $watched_jids] \
+			&&  ($iam == "admin" || $iam == "owner") \
+			&& ![string match *%*@irc* $group]} {
 				[namespace current]::notify_jid $bare_jid $group $nick
 			}
 			if {[info exists jids_by_chats($group)]} {
@@ -247,7 +250,7 @@
 				if {[[namespace current]::is_any_integer $options(ver_timeout)]} {
 					set vto [expr $options(ver_timeout) * 1000]
 				} else {
-					set vto 90000
+					set vto 120000
 				}
 				set pid [after $vto \
 				[namespace current]::process_ver [list $nick $ts $group $real_jid $role_aff]]



More information about the Tkabber-dev mailing list