File: bomstrip.php

package info (click to toggle)
bomstrip 9-2
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 172 kB
  • ctags: 24
  • sloc: pascal: 41; makefile: 41; cpp: 34; ansic: 33; java: 33; python: 31; sh: 24; perl: 7; haskell: 6; php: 6; ruby: 6; awk: 2; sed: 1
file content (12 lines) | stat: -rwxr-xr-x 274 bytes parent folder | download | duplicates (10)
1
2
3
4
5
6
7
8
9
10
11
12
#!/usr/bin/env php 
<?php // written by Andrew Gerrand nf@wh3rd.net http://nf.wh3rd.net/
      // this program is in the public domain

$fp = fopen('php://stdin','r');
$str = fread($fp, 3);
if ($str != "\xef\xbb\xbf")
    printf("%s",$str);
fpassthru($fp);
fclose($fp);

?>