Clearquest
view release on metacpan or search on metacpan
lib/Clearquest/Server.pm view on Meta::CPAN
$self->_debug ("Parent produced child [$childpid]");
} else {
# In child process - ServiceClient
$self->{pid} = $$;
# Now exec the caller but set STDIN to be the socket. Also pass
# -serviceClient to the caller which will need to handle that and call
# _serviceClient.
$self->_debug ("Client: $client");
open STDIN, '+<&', $client
or croak "Unable to dup client";
my $cmd =
"cqperl \"$FindBin::Bin/$FindBin::Script -serviceClient=$self->{clientname} -verbose -debug";
$self->_debug ("Execing: $cmd");
exec 'cqperl', "\"$FindBin::Bin/$FindBin::Script\"",
"-serviceClient=$self->{clientname}", '-verbose', '-debug'
or croak "Unable to exec $cmd";
} # if
} else {
$self->_serviceClient ($client);
} # if
} # while
# On Windows we can't catch SIGCHLD so we need to loop around. Ugly!
goto LOOP if $^O =~ /win/i;
} # startServer
1;
=pod
=head1 CONFIGURATION AND ENVIRONMENT
DEBUG: If set then $debug is set to this level.
VERBOSE: If set then $verbose is set to this level.
TRACE: If set then $trace is set to this level.
=head1 DEPENDENCIES
=head2 Perl Modules
L<Carp>
L<File::Basename|File::Basename>
L<FindBin>
L<IO::Socket|IO::Socket>
L<Net::hostent|Net::hostent>
L<POSIX>
=head1 BUGS AND LIMITATIONS
There are no known bugs in this module.
Please report problems to Andrew DeFaria <Andrew@DeFaria.com>.
=head1 LICENSE AND COPYRIGHT
Copyright (C) 2007-2026 Andrew DeFaria <Andrew@DeFaria.com>
This program is free software; you can redistribute it and/or modify it
under the terms of the the Artistic License (2.0). You may obtain a
copy of the full license at:
L<http://www.perlfoundation.org/artistic_license_2_0>
Any use, modification, and distribution of the Standard or Modified
Versions is governed by this Artistic License. By using, modifying or
distributing the Package, you accept this license. Do not use, modify,
or distribute the Package, if you do not accept this license.
If your Modified Version has been derived from a Modified Version made
by someone else, you are strictly prohibited from removing any
copyright notice from that Modified Version.
Copyright Holder makes no, and expressly disclaims any, representation
or warranty, should the Package be used for any purpose. The liability
of the Copyright Holder is limited to the maximum extent permitted by
law.
=cut
( run in 0.693 second using v1.01-cache-2.11-cpan-39bf76dae61 )