static FILE *gunzip(const char *fn,const char *mode) { FILE *fp; char buf[256]; sprintf(buf,"gunzip -c < %s",fn); fprintf(stderr,"Going to execute '%s'\n",buf); if ((fp=popen(buf,mode)) == NULL) gmx_open(fn); push_ps(fp); return fp; }
static FILE *uncompress(const char *fn, const char *mode) { FILE *fp; char buf[256]; sprintf(buf, "uncompress -c < %s", fn); fprintf(stderr, "Going to execute '%s'\n", buf); if ((fp = popen(buf, mode)) == NULL) { gmx_open(fn); } push_ps(fp); return fp; }