sub client_main($) { my $socket = @_; print "$socket \n"; # some processing # }