Commits

Nzen committed 5ee4090

Still unworking

Hadn't initialized PhysicalLayer in Server. New problem: Client receives
"11111 " from the first handshake which produces numberformatexception
when given to PhysicalLayer.decoder. Something is appending to specialOut?

I forgot to undo debugging on line ~72 that inactivates branch. I have to
leave now.

  • Participants
  • Parent commits 2c36320
  • Branches np

Comments (0)

Files changed (1)

 		int servPort = Integer.parseInt(args[0]);
 		ServerSocket servSock = new ServerSocket(servPort);
 		byteBuffer = new byte[ BUFSIZE ];
+		ethernet = new PhysicalLayer( );
 		System.out.println("Server is now ready to receive clients at port " + servPort);
 		
 		Socket clntSock = servSock.accept();
 		}
 		else
 		{
-			System.out.println( "Server idle" );
+			System.out.println( "Server idle" + ethernet.specialOut( Comm.idle ) );
 			nn = ethernet.specialOut( Comm.idle );
 			byteBuffer = nn.getBytes( );
 			out.write( byteBuffer );