delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp-workers/1998/01/07/14:36:28

Message-Id: <3.0.1.32.19980107133911.007d22a0@yacker.xiotech.com>
Date: Wed, 07 Jan 1998 13:39:11 -0600
To: djgpp-workers AT delorie DOT com
From: Randy Maas <randym AT acm DOT org>
Subject: patch for remove
Mime-Version: 1.0

--=====================_884223551==_
Content-Type: text/plain; charset="us-ascii"

This makes it possible for an fsext to implement its own unlink()
Randy
--=====================_884223551==_
Content-Type: text/plain; charset="us-ascii"
Content-Disposition: attachment; filename="remove.dif"

*** /local/src/libc/ansi/stdio/remove.c~1	Sat Aug 31 21:09:32 1996
--- /local/src/libc/ansi/stdio/remove.c	Wed Jan  7 13:15:16 1998
***************
*** 8,12 ****
  #include <go32.h>
  #include <libc/dosio.h>
!  
  int
  remove(const char *fn)
--- 8,13 ----
  #include <go32.h>
  #include <libc/dosio.h>
! #include <sys/fsext.h>
! 
  int
  remove(const char *fn)
***************
*** 16,20 ****
    int directory_p;
    int use_lfn = _USE_LFN;
!  
    /* Get the file attribute byte.  */
    attr = _chmod(fn, 0);
--- 17,26 ----
    int directory_p;
    int use_lfn = _USE_LFN;
!   int rv;
! 
!   /* see if a file system extension wants to handle this */
!   if (__FSEXT_call_open_handlers(__FSEXT_unlink, &rv, &fn))
!     return rv;
! 
    /* Get the file attribute byte.  */
    attr = _chmod(fn, 0);

--=====================_884223551==_
Content-Type: text/plain; charset="us-ascii"



--=====================_884223551==_--

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019