Message-Id: <3.0.1.32.19980107133539.007d4570@yacker.xiotech.com> Date: Wed, 07 Jan 1998 13:35:39 -0600 To: djgpp-workers AT delorie DOT com From: Randy Maas Subject: patch for fstat Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=====================_884223339==_" Precedence: bulk --=====================_884223339==_ Content-Type: text/plain; charset="us-ascii" This makes it possible for a fsext to give a status report on its file descriptor Randy --=====================_884223339==_ Content-Type: text/plain; charset="us-ascii" Content-Disposition: attachment; filename="fstat.dif" *** /local/src/libc/posix/sys/stat/fstat.c~1 Thu Jan 1 23:32:22 1998 --- /local/src/libc/posix/sys/stat/fstat.c Wed Jan 7 13:11:20 1998 *************** *** 107,111 **** #include #include ! #include "xstat.h" --- 107,111 ---- #include #include ! #include #include "xstat.h" *************** *** 840,843 **** --- 840,845 ---- { int e = errno; /* save previous value of errno */ + __FSEXT_function* func; + int rv; if (!statbuf) *************** *** 845,848 **** --- 847,857 ---- errno = EFAULT; return -1; + } + + /* see if this is file system extension file */ + func = __FSEXT_get_function(handle); + if (func && func(__FSEXT_fstat, &rv, &handle)) + { + return rv; } --=====================_884223339==_ Content-Type: text/plain; charset="us-ascii" --=====================_884223339==_--