home *** CD-ROM | disk | FTP | other *** search
- /* This is an extremely simple and silly substitute for cp(1) for
- OS/2 systems without the GNU Fileutils installed. It does not even
- try to act like a complete 'cp'. */
-
- #include <stdio.h>
- #include <os2.h>
- #define INCL_DOSFILEMGR
-
- int main(int argc, char* argv[])
- {
- APIRET rc;
- if (argc != 3)
- {
- fprintf(stderr, "lcp is a stupid program that only copies one
- file to some file or directory, so only give
- it (exactly) two arguments, please.\n");
- return 2;
- }
- else
- {
- rc = DosCopy(argv[1], argv[2], DCPY_EXISTING);
- return rc;
- }
- }
-