1 eval '(exit $?0)' && eval 'exec perl -S $0 ${1+"$@"}'
2 & eval 'exec perl -S $0 $argv:q'
7 use lib
"$ENV{ACE_ROOT}/bin";
8 use PerlACE
::TestTarget
;
21 my $server = PerlACE
::TestTarget
::create_target
(1) || die "Create target 1 failed\n";
22 my $client = PerlACE
::TestTarget
::create_target
(2) || die "Create target 2 failed\n";
24 $TARGETHOSTNAME = $server->HostName();
25 $port = $server->RandomPort();
27 my $iorbase = "server.ior";
28 my $server_iorfile = $server->LocalFile ($iorbase);
29 $server->DeleteFile($iorbase);
31 $SV = $server->CreateProcess ("server",
32 "-ORBdebuglevel $debug_level " .
33 "-ORBEndpoint iiop://:$port " .
34 "-o $server_iorfile");
36 $CL1 = $client->CreateProcess ("client",
37 "-ORBdebuglevel $debug_level -k \"corbaloc:iiop:$TARGETHOSTNAME:$port/Name\\2dwith\\2dhyphens\"");
39 $CL2 = $client->CreateProcess ("client",
40 "-ORBdebuglevel $debug_level -s -k corbaloc:iiop:$TARGETHOSTNAME:$port/Name%2dwith%2dhyphens");
43 $server_status = $SV->Spawn ();
45 if ($server_status != 0) {
46 print STDERR
"ERROR: server returned $server_status\n";
50 if ($server->WaitForFileTimed ($iorbase,
51 $server->ProcessStartWaitInterval()) == -1) {
52 print STDERR
"ERROR: cannot find file <$server_iorfile>\n";
53 $SV->Kill (); $SV->TimedWait (1);
57 $client_status = $CL1->SpawnWaitKill ($client->ProcessStartWaitInterval());
59 if ($client_status != 0) {
60 print STDERR
"ERROR: Bug 1330 Regression failed. Correct escape characters rejected\n";
64 $client_status = $CL2->SpawnWaitKill ($client->ProcessStartWaitInterval());
66 if ($client_status != 0) {
67 print STDERR
"ERROR: Bug 1330 Regression failed. Correct escape characters rejected\n";
71 $server_status = $SV->WaitKill ($server->ProcessStopWaitInterval());
73 if ($server_status != 0) {
74 print STDERR
"ERROR: server returned $server_status\n";
78 $server->DeleteFile($iorbase);