From 83c0a6e1ce7292792401093acb575761f2a0875b Mon Sep 17 00:00:00 2001 From: bustico Date: Tue, 17 Oct 2006 14:41:37 +0000 Subject: fix a big incompability in bonjour message between ivy-perl and others inmplementations (uuid and appName were swapped) --- Ivy.pm | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'Ivy.pm') diff --git a/Ivy.pm b/Ivy.pm index 5f0b145..ae2bba4 100644 --- a/Ivy.pm +++ b/Ivy.pm @@ -46,7 +46,7 @@ use Fcntl qw(F_GETFL F_SETFL O_NONBLOCK); # to compute the VERSION from the CVS tag (or if no tag, as the cvs file revision) my $TAG= q$Name$; my $REVISION = q$Revision$ ; -$VERSION = '1.46' ; # for Makefile.PL +$VERSION = '1.47' ; # for Makefile.PL ($VERSION) = $TAG =~ /^\D*([\d_]+)/ ; if (defined $VERSION and $VERSION ne "_") { $VERSION =~ s/_/\./g; @@ -758,7 +758,7 @@ sub start # le message de bonjour à envoyer: "no de version no de port" my $bonjourMsg = sprintf ("%d %d %s %s\n", IVY_PROTOCOLE_VERSION, $connSock->sockport(), - $self->[appName], $self->[uuid]); + $self->[uuid], $self->[appName]); if (!$self->[useMulticast]) { # cree la socket de broadcast @@ -1303,7 +1303,7 @@ sub _getBonjour ($) my $peerName = _getHostByAddr ($addr); # on force $peerPort a etre vu comme une valeur numerique - my ($version, $peerPort, $udpAppName, $uuid) = + my ($version, $peerPort, $uuid, $udpAppName) = # $bonjourMsg =~ /^(\d+)\s+(\d+)\s+(?:(\w+)\s+(.*))?/; $bonjourMsg =~ /^(\d+)\s+(\d+)(?:\s+(\S+)\s+(.*))?\n/; @@ -1336,9 +1336,9 @@ sub _getBonjour ($) # print "DBG> from $self->[appName] DISCARD bonjour de $peerName:$peerPort:$uuid [$udpAppName] DEJA CONNECTE\n" ; return; } else { -# print "DBG> reception de $peerName : bonjour $udpAppName:$peerPort" ; -# print " uuid=$uuid" if (defined $uuid); -# print ("\n"); +# print "DBG> reception de $peerName : bonjour $udpAppName:$peerPort" ; +# print " uuid=$uuid" if (defined $uuid); +# print ("\n"); # print "DBG> from $self->[appName] ACCEPT bonjour de $peerName:$peerPort:$uuid [$udpAppName]\n" ; $self->[connectedUuid]->{$uuid} = 1 if (defined $uuid); } -- cgit v1.1