/************************************************************************ * * * Copyright Digital Equipment Corporation 1998. All rights reserved. * * * * Restricted Rights: Use, duplication, or disclosure by the U.S. * * Government is subject to restrictions as set forth in subparagraph * * (c) (1) (ii) of DFARS 252.227-7013, or in FAR 52.227-19, or in FAR * * 52.227-14 Alt. III, as applicable. * * * * This software is proprietary to and embodies the confidential * * technology of Digital Equipment Corporation. Possession, use, or * * copying of this software and media is authorized only pursuant to a * * valid written license from Digital or an authorized sublicensor. * * * ************************************************************************/ /* decc$from_vms_example.c */ /* This example must be run as a foreign command */ /* adn be supplied with a VMS file specification */ #include #include int main(int argc, char *argv[]) { int number_found; /* number of files found */ int print_name(); /* name printer */ printf("Translating: %s\n", argv[1]); number_found = decc$from_vms(argv[1], print_name, 1); printf("\n%d files found", number_found); } /* print the name on each line */ print_name(char *name) { printf("\n%s", name); /* will continue as long as success status is returned */ return (1); }