home *** CD-ROM | disk | FTP | other *** search
/ The C Users' Group Library 1994 August / wc-cdrom-cusersgrouplibrary-1994-08.iso / listings / v_01_02 / 1n02055a < prev    next >
Text File  |  1990-07-09  |  266b  |  16 lines

  1. /*
  2. **  Listing 2 - Convert Unix-style pathnames to DOS-style
  3. */
  4.  
  5. #include <stddef.h>
  6. #include <string.h>
  7.  
  8. char *unix2dos(char *path)
  9. {
  10.         char *p;
  11.  
  12.         while (NULL != (p = strchr(path, '/')))
  13.                 *p = '\\';
  14.         return path;
  15. }
  16.