_chmod.c 551 B

123456789101112131415161718192021
  1. /*
  2. Copyright (c) 1990-1999 Info-ZIP. All rights reserved.
  3. See the accompanying file LICENSE, version 1999-Oct-05 or later
  4. (the contents of which are also included in zip.h) for terms of use.
  5. If, for some reason, both of these files are missing, the Info-ZIP license
  6. also may be found at: ftp://ftp.cdrom.com/pub/infozip/license.html
  7. */
  8. /* Change UNIX modes */
  9. #pragma library
  10. #include <sc.h>
  11. int _chmod(const char *fname, short mask)
  12. {
  13. extern char _um2tm_(short);
  14. return _filechange(fname,'p',(size_t) _um2tm_(mask)|0x80);
  15. }