#!/usr/bin/perl

use strict;

my(@headers) = @ARGV;

my($strip);

while (<STDIN>) {
	if (1 ... /^\r?\n?$/) {
		$strip = 0 if (($strip) and !(/^\s+\S/));
		foreach my $header (@headers) {
		    $strip = 1 if (/^${header}:/);
		}
		print($_) unless ($strip);
	} else {
		print($_);
	}
}
