Penguin

Differences between version 2 and revision by previous author of SSM.

Other diffs: Previous Major Revision, Previous Revision, or view the Annotated Edit History

Newer page: version 2 Last edited on Friday, February 18, 2005 8:57:23 am by JohnMcPherson Revert
Older page: version 1 Last edited on Thursday, February 17, 2005 11:02:55 pm by PerryLorier Revert
@@ -6,9 +6,9 @@
  
 The examples join the SSM group (ip-of-sender,232.1.1.1). In a real application you should randomly selected the 232.0.0.0/8 address to avoid conflicts. 
  
 Sender: 
-<pre
+<verbatim
 #include <sys/types.h> 
 #include <sys/socket.h> 
 #include <arpa/inet.h> 
 #include <netinet/in.h> 
@@ -80,13 +80,13 @@
  sleep(1); 
 
  return 0; 
 
-</pre
+</verbatim
  
 And a reciever follows. Use it ./ssm-rec ip.address.of.sender 
  
-<pre
+<verbatim
 #include <sys/types.h> 
 #include <sys/socket.h> 
 #include <arpa/inet.h> 
 #include <netinet/in.h> 
@@ -147,9 +147,9 @@
  write(1,buffer,ret); 
 
  return 0; 
 
-</pre
+</verbatim
  
 I had one major problem while trying to debug this. My mistake was that the reciever wasn't binding to INADDR_ANY for the listening socket, but instead to an IP address on the machine causing all the multicast packets to be ignored. Ooops. 
 ---- 
 CategoryProgramming CategoryNetworking