/*Last Modified: 6-MAR-1992 15:10:12.45, By: MARK */
/*
* This file contains routines to deal with special types of files.
* including compressed text and shell scripts.
*/
#include "vmsgopherd.h"
/* Check to see if this file needs special treatment before heading
* back to the client... We will check for:
* Compressed files if so, zcat first
* Shellscript if so, "do it"
* Note: it would be somewhat non-portable to check of a binary
* (we'd need to check for so many different magic numbers; the
* shell script designation should be sufficient, since the script
* can call an executable anyway
* Recognized elsewhere:
* .snd needs special processing on client
* uuencoded needs special processing on client
* Other filetypes we could check for:
* GIF -> Bring up GIF previewer
* Postscript -> Bring up Postscript previewer
*/
static int ispipe;
FILE *
specialfile(fp, pathname)
FILE *fp;
char *pathname;
{
FILE *pp;
char buf[256], s[256], outfile[256];
long i;
unsigned int pid;
int ret_status, iosb[2], itmlst;