[Tkabber-dev] r989 - in trunk/tkabber: . doc

tkabber-svn at jabber.ru tkabber-svn at jabber.ru
Thu Mar 1 20:16:21 MSK 2007


Author: sergei
Date: 2007-03-01 20:16:19 +0300 (Thu, 01 Mar 2007)
New Revision: 989

Modified:
   trunk/tkabber/ChangeLog
   trunk/tkabber/doc/tkabber.xml
   trunk/tkabber/gpgme.tcl
Log:
	* doc/tkabber.xml: Added note about new privacy lists case.

	* gpgme.tcl: Fixed inconsistent behaviour when chat window icon
	  indicated unencrypted state and in fact the messages were encrypted.


Modified: trunk/tkabber/ChangeLog
===================================================================
--- trunk/tkabber/ChangeLog	2007-02-28 20:08:28 UTC (rev 988)
+++ trunk/tkabber/ChangeLog	2007-03-01 17:16:19 UTC (rev 989)
@@ -1,3 +1,10 @@
+2007-03-01  Sergei Golovan  <sgolovan at nes.ru>
+
+	* doc/tkabber.xml: Added note about new privacy lists case.
+
+	* gpgme.tcl: Fixed inconsistent behaviour when chat window icon
+	  indicated unencrypted state and in fact the messages were encrypted.
+
 2007-02-28  Sergei Golovan  <sgolovan at nes.ru>
 
 	* plugins/chat/logger.tcl: Don't strip resource from JID when showing

Modified: trunk/tkabber/doc/tkabber.xml
===================================================================
--- trunk/tkabber/doc/tkabber.xml	2007-02-28 20:08:28 UTC (rev 988)
+++ trunk/tkabber/doc/tkabber.xml	2007-03-01 17:16:19 UTC (rev 989)
@@ -2157,6 +2157,7 @@
 	  <list style='symbols'>
 	    <t>New artwork by Artem Bannikov</t>
 	    <t>Mediated SOCKS5 connection support for file transfer (XEP-0065)</t>
+	    <t>Blocking communicaation with users not in roster (using XEP-0016 via simple interface)</t>
 	    <t>Translatable outgoing error messages support (based on recipient's xml:lang)</t>
 	    <t>Remote controlling clients support (XEP-0146)</t>
 	    <t>Extended stanza addressing support (XEP-0033)</t>

Modified: trunk/tkabber/gpgme.tcl
===================================================================
--- trunk/tkabber/gpgme.tcl	2007-02-28 20:08:28 UTC (rev 988)
+++ trunk/tkabber/gpgme.tcl	2007-03-01 17:16:19 UTC (rev 989)
@@ -796,20 +796,18 @@
         return
     }
 
-    #if {[cequal [set jid [roster::find_jid $to]] ""]} {
-    #    set jid $to
-    #}
-    set jid [node_and_server_from_jid $to]
-    if {![encryptP $connid $jid]} {
+    if {![encryptP $connid $to]} {
         return
     }
 
+    set bto [node_and_server_from_jid $to]
+
     if {[info exists j2k($to)]} {
         set name $j2k($to)
     } elseif {[llength [set k [array names j2k $to/*]]] > 0} {
         set name $j2k([lindex $k 0])
     } else {
-        set name $jid
+        set name $bto
     }
 
     set recipient [gpgme::recipient]
@@ -837,7 +835,7 @@
     if {$code} {
         debugmsg ssj "encryption processing error ($connid): $result ($data)"
 
-        set options(encrypt,$connid,$jid) 0
+        set options(encrypt,$connid,$to) 0
         incr gpg_error_id
         if {[MessageDlg .encrypt_error$gpg_error_id \
 		-aspect 50000 \
@@ -981,10 +979,16 @@
 	}
     }
 
+    set bjid [node_and_server_from_jid $jid]
+
     if {[info exists options(encrypt,$connid,$jid)]} {
         return $options(encrypt,$connid,$jid)
+    } elseif {[info exists options(encrypt,$connid,$bjid)]} {
+        return $options(encrypt,$connid,$bjid)
     } elseif {[info exists options(encrypt,$jid)]} {
 	return $options(encrypt,$jid)
+    } elseif {[info exists options(encrypt,$bjid)]} {
+	return $options(encrypt,$jid)
     }
 
     if {!$options(encrypt-traffic)} {
@@ -1002,7 +1006,7 @@
     } elseif {($resP) && ([llength [set k [array names j2k $jid/*]]] > 0)} {
         set name $j2k([lindex $k 0])
     } else {
-        set name $jid
+        set name $bjid
     }
 
     [set recipient [gpgme::recipient]] \



More information about the Tkabber-dev mailing list