File: 01-httpd.pl

package info (click to toggle)
libnet-server-ss-prefork-perl 0.05-2
  • links: PTS, VCS
  • area: main
  • in suites: bookworm, forky, sid, trixie
  • size: 212 kB
  • sloc: perl: 2,094; makefile: 2
file content (20 lines) | stat: -rwxr-xr-x 320 bytes parent folder | download | duplicates (3)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#! /usr/bin/perl

use strict;
use warnings;

use lib qw(blib/lib lib);

my $server = MyServer->new()->run();

package MyServer;

use base qw(HTTP::Server::Simple::CGI);

sub net_server { 'Net::Server::SS::PreFork' };

sub handle_request {
    print "HTTP/1.0 200 OK\r\nContent-Type: text/plain\r\n\r\n" . getppid;
}

1;