diff options
author | cvs2svn <> | 2009-12-18 00:48:50 +0300 |
---|---|---|
committer | cvs2svn <> | 2009-12-18 00:48:50 +0300 |
commit | f522b1317829affd35914f053dfb219c1e20dae0 (patch) | |
tree | 38f475cad35aeece7805088ca23161f3ec538e2a /winsup/cygwin/fhandler_disk_file.cc | |
parent | b292054cac7f3b99d02b49987e7d435c6edb90a7 (diff) |
This commit was manufactured by cvs2svn to create tag 'newlib-1_18_0'.newlib-1_18_0
Sprout from master 2009-12-17 21:48:49 UTC Jeff Johnston <jjohnstn@redhat.com> ''
Cherrypick from cygnus 1999-05-03 07:29:06 UTC Richard Henderson <rth@redhat.com> '19990502 sourceware import':
README
config/mt-d30v
config/mt-netware
config/mt-ospace
etc/add-log.el
etc/add-log.vi
etc/configbuild.ein
etc/configbuild.fig
etc/configbuild.jin
etc/configbuild.tin
etc/configdev.ein
etc/configdev.fig
etc/configdev.jin
etc/configdev.tin
makefile.vms
Delete:
djunpack.bat
include/COPYING
include/COPYING3
include/ChangeLog
include/ChangeLog-9103
include/MAINTAINERS
include/alloca-conf.h
include/ansidecl.h
include/aout/ChangeLog
include/aout/adobe.h
include/aout/aout64.h
include/aout/ar.h
include/aout/dynix3.h
include/aout/encap.h
include/aout/host.h
include/aout/hp.h
include/aout/hp300hpux.h
include/aout/hppa.h
include/aout/ranlib.h
include/aout/reloc.h
include/aout/stab.def
include/aout/stab_gnu.h
include/aout/sun4.h
include/bfdlink.h
include/binary-io.h
include/bout.h
include/cgen/ChangeLog
include/cgen/basic-modes.h
include/cgen/basic-ops.h
include/cgen/bitset.h
include/coff/ChangeLog
include/coff/ChangeLog-9103
include/coff/alpha.h
include/coff/apollo.h
include/coff/arm.h
include/coff/aux-coff.h
include/coff/ecoff.h
include/coff/external.h
include/coff/go32exe.h
include/coff/h8300.h
include/coff/h8500.h
include/coff/i386.h
include/coff/i860.h
include/coff/i960.h
include/coff/ia64.h
include/coff/internal.h
include/coff/m68k.h
include/coff/m88k.h
include/coff/maxq.h
include/coff/mcore.h
include/coff/mips.h
include/coff/mipspe.h
include/coff/or32.h
include/coff/pe.h
include/coff/powerpc.h
include/coff/rs6000.h
include/coff/rs6k64.h
include/coff/sh.h
include/coff/sparc.h
include/coff/sym.h
include/coff/symconst.h
include/coff/ti.h
include/coff/tic30.h
include/coff/tic4x.h
include/coff/tic54x.h
include/coff/tic80.h
include/coff/w65.h
include/coff/we32k.h
include/coff/x86_64.h
include/coff/xcoff.h
include/coff/z80.h
include/coff/z8k.h
include/demangle.h
include/dis-asm.h
include/dwarf2.h
include/dyn-string.h
include/elf/ChangeLog
include/elf/ChangeLog-9103
include/elf/alpha.h
include/elf/arc.h
include/elf/arm.h
include/elf/avr.h
include/elf/bfin.h
include/elf/common.h
include/elf/cr16.h
include/elf/cr16c.h
include/elf/cris.h
include/elf/crx.h
include/elf/d10v.h
include/elf/d30v.h
include/elf/dlx.h
include/elf/dwarf.h
include/elf/external.h
include/elf/fr30.h
include/elf/frv.h
include/elf/h8.h
include/elf/hppa.h
include/elf/i370.h
include/elf/i386.h
include/elf/i860.h
include/elf/i960.h
include/elf/ia64.h
include/elf/internal.h
include/elf/ip2k.h
include/elf/iq2000.h
include/elf/lm32.h
include/elf/m32c.h
include/elf/m32r.h
include/elf/m68hc11.h
include/elf/m68k.h
include/elf/mcore.h
include/elf/mep.h
include/elf/microblaze.h
include/elf/mips.h
include/elf/mmix.h
include/elf/mn10200.h
include/elf/mn10300.h
include/elf/moxie.h
include/elf/msp430.h
include/elf/mt.h
include/elf/openrisc.h
include/elf/or32.h
include/elf/pj.h
include/elf/ppc.h
include/elf/ppc64.h
include/elf/reloc-macros.h
include/elf/rx.h
include/elf/s390.h
include/elf/score.h
include/elf/sh.h
include/elf/sparc.h
include/elf/spu.h
include/elf/v850.h
include/elf/vax.h
include/elf/vxworks.h
include/elf/x86-64.h
include/elf/xc16x.h
include/elf/xstormy16.h
include/elf/xtensa.h
include/fibheap.h
include/filenames.h
include/floatformat.h
include/fnmatch.h
include/fopen-bin.h
include/fopen-same.h
include/fopen-vms.h
include/gdb/ChangeLog
include/gdb/callback.h
include/gdb/fileio.h
include/gdb/remote-sim.h
include/gdb/signals.h
include/gdb/sim-arm.h
include/gdb/sim-cr16.h
include/gdb/sim-d10v.h
include/gdb/sim-frv.h
include/gdb/sim-h8300.h
include/gdb/sim-lm32.h
include/gdb/sim-m32c.h
include/gdb/sim-ppc.h
include/gdb/sim-rx.h
include/gdb/sim-sh.h
include/gdbm.h
include/getopt.h
include/hashtab.h
include/hp-symtab.h
include/ieee.h
include/libiberty.h
include/lto-symtab.h
include/md5.h
include/nlm/ChangeLog
include/nlm/alpha-ext.h
include/nlm/common.h
include/nlm/external.h
include/nlm/i386-ext.h
include/nlm/internal.h
include/nlm/ppc-ext.h
include/nlm/sparc32-ext.h
include/oasys.h
include/objalloc.h
include/obstack.h
include/opcode/ChangeLog
include/opcode/ChangeLog-9103
include/opcode/alpha.h
include/opcode/arc.h
include/opcode/arm.h
include/opcode/avr.h
include/opcode/bfin.h
include/opcode/cgen.h
include/opcode/convex.h
include/opcode/cr16.h
include/opcode/cris.h
include/opcode/crx.h
include/opcode/d10v.h
include/opcode/d30v.h
include/opcode/dlx.h
include/opcode/h8300.h
include/opcode/hppa.h
include/opcode/i370.h
include/opcode/i386.h
include/opcode/i860.h
include/opcode/i960.h
include/opcode/ia64.h
include/opcode/m68hc11.h
include/opcode/m68k.h
include/opcode/m88k.h
include/opcode/maxq.h
include/opcode/mips.h
include/opcode/mmix.h
include/opcode/mn10200.h
include/opcode/mn10300.h
include/opcode/moxie.h
include/opcode/msp430.h
include/opcode/np1.h
include/opcode/ns32k.h
include/opcode/or32.h
include/opcode/pdp11.h
include/opcode/pj.h
include/opcode/pn.h
include/opcode/ppc.h
include/opcode/pyr.h
include/opcode/rx.h
include/opcode/s390.h
include/opcode/score-datadep.h
include/opcode/score-inst.h
include/opcode/sparc.h
include/opcode/spu-insns.h
include/opcode/spu.h
include/opcode/tahoe.h
include/opcode/tic30.h
include/opcode/tic4x.h
include/opcode/tic54x.h
include/opcode/tic80.h
include/opcode/v850.h
include/opcode/vax.h
include/os9k.h
include/partition.h
include/plugin-api.h
include/progress.h
include/safe-ctype.h
include/sha1.h
include/sort.h
include/splay-tree.h
include/symcat.h
include/xregex.h
include/xregex2.h
include/xtensa-config.h
include/xtensa-isa-internal.h
include/xtensa-isa.h
winsup/COPYING
winsup/CYGWIN_LICENSE
winsup/ChangeLog
winsup/Makefile.common
winsup/Makefile.in
winsup/README
winsup/acinclude.m4
winsup/aclocal.m4
winsup/configure
winsup/configure.in
winsup/cygserver/ChangeLog
winsup/cygserver/Makefile.in
winsup/cygserver/README
winsup/cygserver/aclocal.m4
winsup/cygserver/bsd_helper.cc
winsup/cygserver/bsd_helper.h
winsup/cygserver/bsd_log.cc
winsup/cygserver/bsd_log.h
winsup/cygserver/bsd_mutex.cc
winsup/cygserver/bsd_mutex.h
winsup/cygserver/client.cc
winsup/cygserver/configure
winsup/cygserver/configure.in
winsup/cygserver/cygserver-config
winsup/cygserver/cygserver.cc
winsup/cygserver/cygserver.conf
winsup/cygserver/msg.cc
winsup/cygserver/process.cc
winsup/cygserver/process.h
winsup/cygserver/sem.cc
winsup/cygserver/setpwd.cc
winsup/cygserver/shm.cc
winsup/cygserver/sysv_msg.cc
winsup/cygserver/sysv_sem.cc
winsup/cygserver/sysv_shm.cc
winsup/cygserver/threaded_queue.cc
winsup/cygserver/threaded_queue.h
winsup/cygserver/transport.cc
winsup/cygserver/transport.h
winsup/cygserver/transport_pipes.cc
winsup/cygserver/transport_pipes.h
winsup/cygserver/woutsup.h
winsup/cygwin/ChangeLog
winsup/cygwin/ChangeLog-1995
winsup/cygwin/ChangeLog-1996
winsup/cygwin/ChangeLog-1997
winsup/cygwin/ChangeLog-1998
winsup/cygwin/ChangeLog-1999
winsup/cygwin/ChangeLog-2000
winsup/cygwin/ChangeLog-2001
winsup/cygwin/ChangeLog-2002
winsup/cygwin/ChangeLog-2003
winsup/cygwin/ChangeLog-2004
winsup/cygwin/ChangeLog-2005
winsup/cygwin/ChangeLog-2006
winsup/cygwin/ChangeLog-2007
winsup/cygwin/ChangeLog-2008
winsup/cygwin/Makefile.in
winsup/cygwin/ROADMAP
winsup/cygwin/acconfig.h
winsup/cygwin/aclocal.m4
winsup/cygwin/analyze_sigfe
winsup/cygwin/assert.cc
winsup/cygwin/autoload.cc
winsup/cygwin/automode.c
winsup/cygwin/binmode.c
winsup/cygwin/child_info.h
winsup/cygwin/config.h.in
winsup/cygwin/config/i386/profile.h
winsup/cygwin/configure
winsup/cygwin/configure.in
winsup/cygwin/cpuid.h
winsup/cygwin/crt0.c
winsup/cygwin/ctype.cc
winsup/cygwin/cxx.cc
winsup/cygwin/cygerrno.h
winsup/cygwin/cygheap.cc
winsup/cygwin/cygheap.h
winsup/cygwin/cygheap_malloc.h
winsup/cygwin/cyglsa.h
winsup/cygwin/cygmagic
winsup/cygwin/cygmalloc.h
winsup/cygwin/cygprops.h
winsup/cygwin/cygserver.h
winsup/cygwin/cygserver_ipc.h
winsup/cygwin/cygserver_msg.h
winsup/cygwin/cygserver_sem.h
winsup/cygwin/cygserver_setpwd.h
winsup/cygwin/cygserver_shm.h
winsup/cygwin/cygthread.cc
winsup/cygwin/cygthread.h
winsup/cygwin/cygtls.cc
winsup/cygwin/cygtls.h
winsup/cygwin/cygwin-cxx.h
winsup/cygwin/cygwin-shilka
winsup/cygwin/cygwin.din
winsup/cygwin/cygwin.sc
winsup/cygwin/cygwin_version.h
winsup/cygwin/dcrt0.cc
winsup/cygwin/debug.cc
winsup/cygwin/debug.h
winsup/cygwin/devices.cc
winsup/cygwin/devices.h
winsup/cygwin/devices.in
winsup/cygwin/dir.cc
winsup/cygwin/dlfcn.cc
winsup/cygwin/dll_init.cc
winsup/cygwin/dll_init.h
winsup/cygwin/dll_init.sgml
winsup/cygwin/dllfixdbg
winsup/cygwin/dlmalloc.c
winsup/cygwin/dlmalloc.h
winsup/cygwin/dtable.cc
winsup/cygwin/dtable.h
winsup/cygwin/dtable.sgml
winsup/cygwin/environ.cc
winsup/cygwin/environ.h
winsup/cygwin/errno.cc
winsup/cygwin/exceptions.cc
winsup/cygwin/exec.cc
winsup/cygwin/external.cc
winsup/cygwin/external.sgml
winsup/cygwin/fcntl.cc
winsup/cygwin/fhandler.cc
winsup/cygwin/fhandler.h
winsup/cygwin/fhandler_clipboard.cc
winsup/cygwin/fhandler_console.cc
winsup/cygwin/fhandler_disk_file.cc
winsup/cygwin/fhandler_dsp.cc
winsup/cygwin/fhandler_fifo.cc
winsup/cygwin/fhandler_floppy.cc
winsup/cygwin/fhandler_mailslot.cc
winsup/cygwin/fhandler_mem.cc
winsup/cygwin/fhandler_netdrive.cc
winsup/cygwin/fhandler_nodevice.cc
winsup/cygwin/fhandler_proc.cc
winsup/cygwin/fhandler_process.cc
winsup/cygwin/fhandler_procnet.cc
winsup/cygwin/fhandler_random.cc
winsup/cygwin/fhandler_raw.cc
winsup/cygwin/fhandler_registry.cc
winsup/cygwin/fhandler_serial.cc
winsup/cygwin/fhandler_socket.cc
winsup/cygwin/fhandler_tape.cc
winsup/cygwin/fhandler_termios.cc
winsup/cygwin/fhandler_tty.cc
winsup/cygwin/fhandler_virtual.cc
winsup/cygwin/fhandler_virtual.h
winsup/cygwin/fhandler_windows.cc
winsup/cygwin/fhandler_zero.cc
winsup/cygwin/flock.cc
winsup/cygwin/fork.cc
winsup/cygwin/gcrt0.c
winsup/cygwin/gendef
winsup/cygwin/gendevices
winsup/cygwin/gentls_offsets
winsup/cygwin/glob.cc
winsup/cygwin/glob_pattern_p.cc
winsup/cygwin/globals.cc
winsup/cygwin/gmon.c
winsup/cygwin/gmon.h
winsup/cygwin/grp.cc
winsup/cygwin/heap.cc
winsup/cygwin/heap.h
winsup/cygwin/hires.h
winsup/cygwin/hookapi.cc
winsup/cygwin/how-autoload-works.txt
winsup/cygwin/how-cygheap-works.txt
winsup/cygwin/how-cygtls-works.txt
winsup/cygwin/how-fhandlers-work.txt
winsup/cygwin/how-signals-work.txt
winsup/cygwin/how-spawn-works.txt
winsup/cygwin/how-to-debug-cygwin.txt
winsup/cygwin/how-vfork-works.txt
winsup/cygwin/include/a.out.h
winsup/cygwin/include/arpa/ftp.h
winsup/cygwin/include/arpa/inet.h
winsup/cygwin/include/arpa/nameser.h
winsup/cygwin/include/arpa/nameser_compat.h
winsup/cygwin/include/arpa/telnet.h
winsup/cygwin/include/asm/byteorder.h
winsup/cygwin/include/asm/socket.h
winsup/cygwin/include/asm/types.h
winsup/cygwin/include/attr/xattr.h
winsup/cygwin/include/bits/wordsize.h
winsup/cygwin/include/byteswap.h
winsup/cygwin/include/cygwin/_types.h
winsup/cygwin/include/cygwin/acl.h
winsup/cygwin/include/cygwin/config.h
winsup/cygwin/include/cygwin/core_dump.h
winsup/cygwin/include/cygwin/cygwin_dll.h
winsup/cygwin/include/cygwin/fs.h
winsup/cygwin/include/cygwin/grp.h
winsup/cygwin/include/cygwin/hdreg.h
winsup/cygwin/include/cygwin/icmp.h
winsup/cygwin/include/cygwin/if.h
winsup/cygwin/include/cygwin/in.h
winsup/cygwin/include/cygwin/in6.h
winsup/cygwin/include/cygwin/in_systm.h
winsup/cygwin/include/cygwin/ipc.h
winsup/cygwin/include/cygwin/kd.h
winsup/cygwin/include/cygwin/msg.h
winsup/cygwin/include/cygwin/mtio.h
winsup/cygwin/include/cygwin/rdevio.h
winsup/cygwin/include/cygwin/sem.h
winsup/cygwin/include/cygwin/shm.h
winsup/cygwin/include/cygwin/signal.h
winsup/cygwin/include/cygwin/socket.h
winsup/cygwin/include/cygwin/sockios.h
winsup/cygwin/include/cygwin/stat.h
winsup/cygwin/include/cygwin/stdlib.h
winsup/cygwin/include/cygwin/sys_time.h
winsup/cygwin/include/cygwin/sysproto.h
winsup/cygwin/include/cygwin/time.h
winsup/cygwin/include/cygwin/types.h
winsup/cygwin/include/cygwin/utmp.h
winsup/cygwin/include/cygwin/version.h
winsup/cygwin/include/cygwin/wait.h
winsup/cygwin/include/dlfcn.h
winsup/cygwin/include/elf.h
winsup/cygwin/include/endian.h
winsup/cygwin/include/err.h
winsup/cygwin/include/exceptions.h
winsup/cygwin/include/fcntl.h
winsup/cygwin/include/features.h
winsup/cygwin/include/fnmatch.h
winsup/cygwin/include/fts.h
winsup/cygwin/include/ftw.h
winsup/cygwin/include/getopt.h
winsup/cygwin/include/glob.h
winsup/cygwin/include/icmp.h
winsup/cygwin/include/ifaddrs.h
winsup/cygwin/include/inttypes.h
winsup/cygwin/include/io.h
winsup/cygwin/include/lastlog.h
winsup/cygwin/include/libgen.h
winsup/cygwin/include/limits.h
winsup/cygwin/include/machine/stdlib.h
winsup/cygwin/include/mapi.h
winsup/cygwin/include/memory.h
winsup/cygwin/include/mntent.h
winsup/cygwin/include/mqueue.h
winsup/cygwin/include/net/if.h
winsup/cygwin/include/netdb.h
winsup/cygwin/include/netinet/in.h
winsup/cygwin/include/netinet/in_systm.h
winsup/cygwin/include/netinet/ip.h
winsup/cygwin/include/netinet/ip_icmp.h
winsup/cygwin/include/netinet/tcp.h
winsup/cygwin/include/netinet/udp.h
winsup/cygwin/include/paths.h
winsup/cygwin/include/poll.h
winsup/cygwin/include/pthread.h
winsup/cygwin/include/pty.h
winsup/cygwin/include/resolv.h
winsup/cygwin/include/sched.h
winsup/cygwin/include/search.h
winsup/cygwin/include/semaphore.h
winsup/cygwin/include/stdint.h
winsup/cygwin/include/strings.h
winsup/cygwin/include/sys/acl.h
winsup/cygwin/include/sys/copying.dj
winsup/cygwin/include/sys/cygwin.h
winsup/cygwin/include/sys/dirent.h
winsup/cygwin/include/sys/elf32.h
winsup/cygwin/include/sys/elf64.h
winsup/cygwin/include/sys/elf_common.h
winsup/cygwin/include/sys/elf_generic.h
winsup/cygwin/include/sys/file.h
winsup/cygwin/include/sys/ioctl.h
winsup/cygwin/include/sys/ipc.h
winsup/cygwin/include/sys/kd.h
winsup/cygwin/include/sys/lock.h
winsup/cygwin/include/sys/mman.h
winsup/cygwin/include/sys/mount.h
winsup/cygwin/include/sys/msg.h
winsup/cygwin/include/sys/mtio.h
winsup/cygwin/include/sys/param.h
winsup/cygwin/include/sys/poll.h
winsup/cygwin/include/sys/procfs.h
winsup/cygwin/include/sys/queue.h
winsup/cygwin/include/sys/resource.h
winsup/cygwin/include/sys/sched.h
winsup/cygwin/include/sys/select.h
winsup/cygwin/include/sys/sem.h
winsup/cygwin/include/sys/shm.h
winsup/cygwin/include/sys/smallprint.h
winsup/cygwin/include/sys/socket.h
winsup/cygwin/include/sys/soundcard.h
winsup/cygwin/include/sys/statfs.h
winsup/cygwin/include/sys/statvfs.h
winsup/cygwin/include/sys/stdio.h
winsup/cygwin/include/sys/strace.h
winsup/cygwin/include/sys/sysinfo.h
winsup/cygwin/include/sys/syslimits.h
winsup/cygwin/include/sys/syslog.h
winsup/cygwin/include/sys/sysmacros.h
winsup/cygwin/include/sys/sysproto.h
winsup/cygwin/include/sys/termio.h
winsup/cygwin/include/sys/termios.h
winsup/cygwin/include/sys/ttychars.h
winsup/cygwin/include/sys/uio.h
winsup/cygwin/include/sys/un.h
winsup/cygwin/include/sys/utime.h
winsup/cygwin/include/sys/utmp.h
winsup/cygwin/include/sys/utsname.h
winsup/cygwin/include/sys/vfs.h
winsup/cygwin/include/sys/wait.h
winsup/cygwin/include/sysexits.h
winsup/cygwin/include/syslog.h
winsup/cygwin/include/termio.h
winsup/cygwin/include/tzfile.h
winsup/cygwin/include/utmpx.h
winsup/cygwin/include/wait.h
winsup/cygwin/init.cc
winsup/cygwin/ioctl.cc
winsup/cygwin/ipc.cc
winsup/cygwin/kernel32.cc
winsup/cygwin/lib/_cygwin_crt0_common.cc
winsup/cygwin/lib/crt0.h
winsup/cygwin/lib/cygwin_attach_dll.c
winsup/cygwin/lib/cygwin_crt0.c
winsup/cygwin/lib/dll_entry.c
winsup/cygwin/lib/dll_main.cc
winsup/cygwin/lib/libcmain.c
winsup/cygwin/lib/premain0.c
winsup/cygwin/lib/premain1.c
winsup/cygwin/lib/premain2.c
winsup/cygwin/lib/premain3.c
winsup/cygwin/lib/pseudo-reloc.c
winsup/cygwin/libc/bsdlib.cc
winsup/cygwin/libc/fnmatch.c
winsup/cygwin/libc/fts.c
winsup/cygwin/libc/ftw.c
winsup/cygwin/libc/getopt.c
winsup/cygwin/libc/inet_addr.c
winsup/cygwin/libc/inet_network.c
winsup/cygwin/libc/minires-os-if.c
winsup/cygwin/libc/minires.c
winsup/cygwin/libc/minires.h
winsup/cygwin/libc/nftw.c
winsup/cygwin/libc/rcmd.cc
winsup/cygwin/libc/rexec.cc
winsup/cygwin/libc/strptime.cc
winsup/cygwin/libc/xsique.cc
winsup/cygwin/libstdcxx_wrapper.cc
winsup/cygwin/localtime.cc
winsup/cygwin/lsearch.cc
winsup/cygwin/malloc.cc
winsup/cygwin/malloc_wrapper.cc
winsup/cygwin/mcount.c
winsup/cygwin/miscfuncs.cc
winsup/cygwin/miscfuncs.h
winsup/cygwin/mkglobals_h
winsup/cygwin/mkimport
winsup/cygwin/mkstatic
winsup/cygwin/mktemp.cc
winsup/cygwin/mkvers.sh
winsup/cygwin/mmap.cc
winsup/cygwin/mmap_helper.h
winsup/cygwin/mount.cc
winsup/cygwin/mount.h
winsup/cygwin/msg.cc
winsup/cygwin/mtinfo.h
winsup/cygwin/net.cc
winsup/cygwin/netdb.cc
winsup/cygwin/nfs.cc
winsup/cygwin/nfs.h
winsup/cygwin/ntdll.h
winsup/cygwin/ntea.cc
winsup/cygwin/passwd.cc
winsup/cygwin/path.cc
winsup/cygwin/path.h
winsup/cygwin/path.sgml
winsup/cygwin/perprocess.h
winsup/cygwin/pinfo.cc
winsup/cygwin/pinfo.h
winsup/cygwin/pipe.cc
winsup/cygwin/poll.cc
winsup/cygwin/posix.sgml
winsup/cygwin/posix_ipc.cc
winsup/cygwin/profil.c
winsup/cygwin/profil.h
winsup/cygwin/pseudo-reloc.cc
winsup/cygwin/pthread.cc
winsup/cygwin/pwdgrp.h
winsup/cygwin/random.cc
winsup/cygwin/regex/COPYRIGHT
winsup/cygwin/regex/cclass.h
winsup/cygwin/regex/cname.h
winsup/cygwin/regex/engine.c
winsup/cygwin/regex/engine.ih
winsup/cygwin/regex/mkh
winsup/cygwin/regex/regcomp.c
winsup/cygwin/regex/regcomp.ih
winsup/cygwin/regex/regerror.c
winsup/cygwin/regex/regerror.ih
winsup/cygwin/regex/regex.3
winsup/cygwin/regex/regex.7
winsup/cygwin/regex/regex.h
winsup/cygwin/regex/regex2.h
winsup/cygwin/regex/regexec.c
winsup/cygwin/regex/regfree.c
winsup/cygwin/regex/tests
winsup/cygwin/regex/utils.h
winsup/cygwin/registry.cc
winsup/cygwin/registry.h
winsup/cygwin/resource.cc
winsup/cygwin/scandir.cc
winsup/cygwin/sched.cc
winsup/cygwin/sec_acl.cc
winsup/cygwin/sec_auth.cc
winsup/cygwin/sec_helper.cc
winsup/cygwin/security.cc
winsup/cygwin/security.h
winsup/cygwin/security.sgml
winsup/cygwin/select.cc
winsup/cygwin/select.h
winsup/cygwin/sem.cc
winsup/cygwin/setlsapwd.cc
winsup/cygwin/shared.cc
winsup/cygwin/shared_info.h
winsup/cygwin/shm.cc
winsup/cygwin/signal.cc
winsup/cygwin/sigproc.cc
winsup/cygwin/sigproc.h
winsup/cygwin/smallprint.cc
winsup/cygwin/sortdin
winsup/cygwin/spawn.cc
winsup/cygwin/speclib
winsup/cygwin/stackdump.sgml
winsup/cygwin/strace.cc
winsup/cygwin/strfuncs.cc
winsup/cygwin/string.h
winsup/cygwin/strsep.cc
winsup/cygwin/strsig.cc
winsup/cygwin/sync.cc
winsup/cygwin/sync.h
winsup/cygwin/syscalls.cc
winsup/cygwin/sysconf.cc
winsup/cygwin/syslog.cc
winsup/cygwin/termios.cc
winsup/cygwin/textmode.c
winsup/cygwin/textreadmode.c
winsup/cygwin/thread.cc
winsup/cygwin/thread.h
winsup/cygwin/timer.cc
winsup/cygwin/times.cc
winsup/cygwin/tls_pbuf.cc
winsup/cygwin/tls_pbuf.h
winsup/cygwin/tlsoffsets.h
winsup/cygwin/tty.cc
winsup/cygwin/tty.h
winsup/cygwin/tz_posixrules.h
winsup/cygwin/uinfo.cc
winsup/cygwin/uname.cc
winsup/cygwin/wait.cc
winsup/cygwin/wchar.h
winsup/cygwin/winbase.h
winsup/cygwin/wincap.cc
winsup/cygwin/wincap.h
winsup/cygwin/window.cc
winsup/cygwin/winf.cc
winsup/cygwin/winf.h
winsup/cygwin/wininfo.h
winsup/cygwin/winsup.h
winsup/cygwin/winver.rc
winsup/doc/ChangeLog
winsup/doc/Makefile.in
winsup/doc/README
winsup/doc/aclocal.m4
winsup/doc/configure
winsup/doc/configure.in
winsup/doc/cygserver.sgml
winsup/doc/cygwin-api.in.sgml
winsup/doc/cygwin-ug-net.in.sgml
winsup/doc/cygwin-ug.in.sgml
winsup/doc/cygwin.dsl
winsup/doc/cygwinenv.sgml
winsup/doc/dll.sgml
winsup/doc/doctool.c
winsup/doc/doctool.txt
winsup/doc/effectively.sgml
winsup/doc/faq-api.xml
winsup/doc/faq-programming.xml
winsup/doc/faq-resources.xml
winsup/doc/faq-sections.xml
winsup/doc/faq-setup.xml
winsup/doc/faq-using.xml
winsup/doc/faq-what.xml
winsup/doc/faq.xml
winsup/doc/fhandler-tut.txt
winsup/doc/filemodes.sgml
winsup/doc/gcc.sgml
winsup/doc/gdb.sgml
winsup/doc/legal.sgml
winsup/doc/new-features.sgml
winsup/doc/ntsec.sgml
winsup/doc/overview.sgml
winsup/doc/overview2.sgml
winsup/doc/pathnames.sgml
winsup/doc/programming.sgml
winsup/doc/setup-net.sgml
winsup/doc/setup.sgml
winsup/doc/setup2.sgml
winsup/doc/textbinary.sgml
winsup/doc/using.sgml
winsup/doc/windres.sgml
winsup/lsaauth/ChangeLog
winsup/lsaauth/Makefile.in
winsup/lsaauth/aclocal.m4
winsup/lsaauth/configure
winsup/lsaauth/configure.in
winsup/lsaauth/cyglsa-config
winsup/lsaauth/cyglsa.c
winsup/lsaauth/cyglsa.din
winsup/lsaauth/cyglsa64.dll
winsup/lsaauth/make-64bit-version-with-visual-c.bat
winsup/lsaauth/mslsa.def
winsup/mingw/CONTRIBUTORS
winsup/mingw/CRT_fp10.c
winsup/mingw/CRT_fp8.c
winsup/mingw/CRT_noglob.c
winsup/mingw/CRTfmode.c
winsup/mingw/CRTglob.c
winsup/mingw/CRTinit.c
winsup/mingw/ChangeLog
winsup/mingw/DISCLAIMER
winsup/mingw/Makefile.in
winsup/mingw/README
winsup/mingw/TODO
winsup/mingw/aclocal.m4
winsup/mingw/binmode.c
winsup/mingw/config.guess
winsup/mingw/config.sub
winsup/mingw/configure
winsup/mingw/configure.in
winsup/mingw/cpu_features.c
winsup/mingw/cpu_features.h
winsup/mingw/crt1.c
winsup/mingw/crtdll.def
winsup/mingw/crtmt.c
winsup/mingw/crtst.c
winsup/mingw/dllcrt1.c
winsup/mingw/dllmain.c
winsup/mingw/gccmain.c
winsup/mingw/include/_mingw.h
winsup/mingw/include/assert.h
winsup/mingw/include/complex.h
winsup/mingw/include/conio.h
winsup/mingw/include/ctype.h
winsup/mingw/include/dir.h
winsup/mingw/include/direct.h
winsup/mingw/include/dirent.h
winsup/mingw/include/dos.h
winsup/mingw/include/errno.h
winsup/mingw/include/excpt.h
winsup/mingw/include/fcntl.h
winsup/mingw/include/fenv.h
winsup/mingw/include/float.h
winsup/mingw/include/getopt.h
winsup/mingw/include/inttypes.h
winsup/mingw/include/io.h
winsup/mingw/include/libgen.h
winsup/mingw/include/limits.h
winsup/mingw/include/locale.h
winsup/mingw/include/malloc.h
winsup/mingw/include/math.h
winsup/mingw/include/mbctype.h
winsup/mingw/include/mbstring.h
winsup/mingw/include/mem.h
winsup/mingw/include/memory.h
winsup/mingw/include/process.h
winsup/mingw/include/search.h
winsup/mingw/include/setjmp.h
winsup/mingw/include/share.h
winsup/mingw/include/signal.h
winsup/mingw/include/stdint.h
winsup/mingw/include/stdio.h
winsup/mingw/include/stdlib.h
winsup/mingw/include/string.h
winsup/mingw/include/strings.h
winsup/mingw/include/sys/fcntl.h
winsup/mingw/include/sys/file.h
winsup/mingw/include/sys/locking.h
winsup/mingw/include/sys/param.h
winsup/mingw/include/sys/stat.h
winsup/mingw/include/sys/time.h
winsup/mingw/include/sys/timeb.h
winsup/mingw/include/sys/types.h
winsup/mingw/include/sys/unistd.h
winsup/mingw/include/sys/utime.h
winsup/mingw/include/tchar.h
winsup/mingw/include/time.h
winsup/mingw/include/unistd.h
winsup/mingw/include/utime.h
winsup/mingw/include/values.h
winsup/mingw/include/varargs.h
winsup/mingw/include/wchar.h
winsup/mingw/include/wctype.h
winsup/mingw/init.c
winsup/mingw/install-sh
winsup/mingw/isascii.c
winsup/mingw/iscsym.c
winsup/mingw/iscsymf.c
winsup/mingw/jamfile
winsup/mingw/main.c
winsup/mingw/man/dirname.man
winsup/mingw/mingwex/Makefile.in
winsup/mingw/mingwex/_Exit.c
winsup/mingw/mingwex/atoll.c
winsup/mingw/mingwex/basename.c
winsup/mingw/mingwex/btowc.c
winsup/mingw/mingwex/complex/cabs.c
winsup/mingw/mingwex/complex/cabsf.c
winsup/mingw/mingwex/complex/cabsl.c
winsup/mingw/mingwex/complex/cacos.c
winsup/mingw/mingwex/complex/cacosf.c
winsup/mingw/mingwex/complex/cacosh.c
winsup/mingw/mingwex/complex/cacoshf.c
winsup/mingw/mingwex/complex/cacoshl.c
winsup/mingw/mingwex/complex/cacosl.c
winsup/mingw/mingwex/complex/carg.c
winsup/mingw/mingwex/complex/cargf.c
winsup/mingw/mingwex/complex/cargl.c
winsup/mingw/mingwex/complex/casin.c
winsup/mingw/mingwex/complex/casinf.c
winsup/mingw/mingwex/complex/casinh.c
winsup/mingw/mingwex/complex/casinhf.c
winsup/mingw/mingwex/complex/casinhl.c
winsup/mingw/mingwex/complex/casinl.c
winsup/mingw/mingwex/complex/catan.c
winsup/mingw/mingwex/complex/catanf.c
winsup/mingw/mingwex/complex/catanh.c
winsup/mingw/mingwex/complex/catanhf.c
winsup/mingw/mingwex/complex/catanhl.c
winsup/mingw/mingwex/complex/catanl.c
winsup/mingw/mingwex/complex/ccos.c
winsup/mingw/mingwex/complex/ccosf.c
winsup/mingw/mingwex/complex/ccosh.c
winsup/mingw/mingwex/complex/ccoshf.c
winsup/mingw/mingwex/complex/ccoshl.c
winsup/mingw/mingwex/complex/ccosl.c
winsup/mingw/mingwex/complex/cexp.c
winsup/mingw/mingwex/complex/cexpf.c
winsup/mingw/mingwex/complex/cexpl.c
winsup/mingw/mingwex/complex/cimag.c
winsup/mingw/mingwex/complex/cimagf.c
winsup/mingw/mingwex/complex/cimagl.c
winsup/mingw/mingwex/complex/clog.c
winsup/mingw/mingwex/complex/clogf.c
winsup/mingw/mingwex/complex/clogl.c
winsup/mingw/mingwex/complex/cpow.c
winsup/mingw/mingwex/complex/cpowf.c
winsup/mingw/mingwex/complex/cpowl.c
winsup/mingw/mingwex/complex/cproj.c
winsup/mingw/mingwex/complex/cprojf.c
winsup/mingw/mingwex/complex/cprojl.c
winsup/mingw/mingwex/complex/creal.c
winsup/mingw/mingwex/complex/crealf.c
winsup/mingw/mingwex/complex/creall.c
winsup/mingw/mingwex/complex/csin.c
winsup/mingw/mingwex/complex/csinf.c
winsup/mingw/mingwex/complex/csinh.c
winsup/mingw/mingwex/complex/csinhf.c
winsup/mingw/mingwex/complex/csinhl.c
winsup/mingw/mingwex/complex/csinl.c
winsup/mingw/mingwex/complex/csqrt.c
winsup/mingw/mingwex/complex/csqrtf.c
winsup/mingw/mingwex/complex/csqrtl.c
winsup/mingw/mingwex/complex/ctan.c
winsup/mingw/mingwex/complex/ctanf.c
winsup/mingw/mingwex/complex/ctanh.c
winsup/mingw/mingwex/complex/ctanhf.c
winsup/mingw/mingwex/complex/ctanhl.c
winsup/mingw/mingwex/complex/ctanl.c
winsup/mingw/mingwex/dirent.c
winsup/mingw/mingwex/dirname.c
winsup/mingw/mingwex/feclearexcept.c
winsup/mingw/mingwex/fegetenv.c
winsup/mingw/mingwex/fegetexceptflag.c
winsup/mingw/mingwex/fegetround.c
winsup/mingw/mingwex/feholdexcept.c
winsup/mingw/mingwex/feraiseexcept.c
winsup/mingw/mingwex/fesetenv.c
winsup/mingw/mingwex/fesetexceptflag.c
winsup/mingw/mingwex/fesetround.c
winsup/mingw/mingwex/fetestexcept.c
winsup/mingw/mingwex/feupdateenv.c
winsup/mingw/mingwex/ftruncate.c
winsup/mingw/mingwex/fwide.c
winsup/mingw/mingwex/gdtoa/README
winsup/mingw/mingwex/gdtoa/README.mingw
winsup/mingw/mingwex/gdtoa/arithchk.c
winsup/mingw/mingwex/gdtoa/dmisc.c
winsup/mingw/mingwex/gdtoa/dtoa.c
winsup/mingw/mingwex/gdtoa/g__fmt.c
winsup/mingw/mingwex/gdtoa/g_dfmt.c
winsup/mingw/mingwex/gdtoa/g_ffmt.c
winsup/mingw/mingwex/gdtoa/g_xfmt.c
winsup/mingw/mingwex/gdtoa/gd_arith.h
winsup/mingw/mingwex/gdtoa/gd_qnan.h
winsup/mingw/mingwex/gdtoa/gdtoa.c
winsup/mingw/mingwex/gdtoa/gdtoa.h
winsup/mingw/mingwex/gdtoa/gdtoa_fltrnds.h
winsup/mingw/mingwex/gdtoa/gdtoaimp.h
winsup/mingw/mingwex/gdtoa/gethex.c
winsup/mingw/mingwex/gdtoa/gmisc.c
winsup/mingw/mingwex/gdtoa/hd_init.c
winsup/mingw/mingwex/gdtoa/hexnan.c
winsup/mingw/mingwex/gdtoa/misc.c
winsup/mingw/mingwex/gdtoa/qnan.c
winsup/mingw/mingwex/gdtoa/smisc.c
winsup/mingw/mingwex/gdtoa/strtodg.c
winsup/mingw/mingwex/gdtoa/strtodnrp.c
winsup/mingw/mingwex/gdtoa/strtof.c
winsup/mingw/mingwex/gdtoa/strtopx.c
winsup/mingw/mingwex/gdtoa/sum.c
winsup/mingw/mingwex/gdtoa/ulp.c
winsup/mingw/mingwex/getopt.c
winsup/mingw/mingwex/gettimeofday.c
winsup/mingw/mingwex/imaxabs.c
winsup/mingw/mingwex/imaxdiv.c
winsup/mingw/mingwex/isblank.c
winsup/mingw/mingwex/iswblank.c
winsup/mingw/mingwex/lltoa.c
winsup/mingw/mingwex/lltow.c
winsup/mingw/mingwex/math/acosf.c
winsup/mingw/mingwex/math/acosh.c
winsup/mingw/mingwex/math/acoshf.c
winsup/mingw/mingwex/math/acoshl.c
winsup/mingw/mingwex/math/acosl.c
winsup/mingw/mingwex/math/asinf.c
winsup/mingw/mingwex/math/asinh.c
winsup/mingw/mingwex/math/asinhf.c
winsup/mingw/mingwex/math/asinhl.c
winsup/mingw/mingwex/math/asinl.c
winsup/mingw/mingwex/math/atan2f.c
winsup/mingw/mingwex/math/atan2l.c
winsup/mingw/mingwex/math/atanf.c
winsup/mingw/mingwex/math/atanh.c
winsup/mingw/mingwex/math/atanhf.c
winsup/mingw/mingwex/math/atanhl.c
winsup/mingw/mingwex/math/atanl.c
winsup/mingw/mingwex/math/cbrt.c
winsup/mingw/mingwex/math/cbrtf.c
winsup/mingw/mingwex/math/cbrtl.c
winsup/mingw/mingwex/math/ceilf.S
winsup/mingw/mingwex/math/ceill.S
winsup/mingw/mingwex/math/cephes_mconf.h
winsup/mingw/mingwex/math/copysign.S
winsup/mingw/mingwex/math/copysignf.S
winsup/mingw/mingwex/math/copysignl.S
winsup/mingw/mingwex/math/cosf.S
winsup/mingw/mingwex/math/coshf.c
winsup/mingw/mingwex/math/coshl.c
winsup/mingw/mingwex/math/cosl.S
winsup/mingw/mingwex/math/erfl.c
winsup/mingw/mingwex/math/exp2.S
winsup/mingw/mingwex/math/exp2f.S
winsup/mingw/mingwex/math/exp2l.S
winsup/mingw/mingwex/math/expf.c
winsup/mingw/mingwex/math/expl.c
winsup/mingw/mingwex/math/expm1.c
winsup/mingw/mingwex/math/expm1f.c
winsup/mingw/mingwex/math/expm1l.c
winsup/mingw/mingwex/math/fabs.c
winsup/mingw/mingwex/math/fabsf.c
winsup/mingw/mingwex/math/fabsl.c
winsup/mingw/mingwex/math/fastmath.h
winsup/mingw/mingwex/math/fdim.c
winsup/mingw/mingwex/math/fdimf.c
winsup/mingw/mingwex/math/fdiml.c
winsup/mingw/mingwex/math/floorf.S
winsup/mingw/mingwex/math/floorl.S
winsup/mingw/mingwex/math/fma.S
winsup/mingw/mingwex/math/fmaf.S
winsup/mingw/mingwex/math/fmal.c
winsup/mingw/mingwex/math/fmax.c
winsup/mingw/mingwex/math/fmaxf.c
winsup/mingw/mingwex/math/fmaxl.c
winsup/mingw/mingwex/math/fmin.c
winsup/mingw/mingwex/math/fminf.c
winsup/mingw/mingwex/math/fminl.c
winsup/mingw/mingwex/math/fmodf.c
winsup/mingw/mingwex/math/fmodl.c
winsup/mingw/mingwex/math/fp_consts.c
winsup/mingw/mingwex/math/fp_consts.h
winsup/mingw/mingwex/math/fp_constsf.c
winsup/mingw/mingwex/math/fp_constsl.c
winsup/mingw/mingwex/math/fpclassify.c
winsup/mingw/mingwex/math/fpclassifyf.c
winsup/mingw/mingwex/math/fpclassifyl.c
winsup/mingw/mingwex/math/frexpf.c
winsup/mingw/mingwex/math/frexpl.S
winsup/mingw/mingwex/math/fucom.c
winsup/mingw/mingwex/math/hypotf.c
winsup/mingw/mingwex/math/hypotl.c
winsup/mingw/mingwex/math/ilogb.S
winsup/mingw/mingwex/math/ilogbf.S
winsup/mingw/mingwex/math/ilogbl.S
winsup/mingw/mingwex/math/isnan.c
winsup/mingw/mingwex/math/isnanf.c
winsup/mingw/mingwex/math/isnanl.c
winsup/mingw/mingwex/math/ldexpf.c
winsup/mingw/mingwex/math/ldexpl.c
winsup/mingw/mingwex/math/lgamma.c
winsup/mingw/mingwex/math/lgammaf.c
winsup/mingw/mingwex/math/lgammal.c
winsup/mingw/mingwex/math/llrint.c
winsup/mingw/mingwex/math/llrintf.c
winsup/mingw/mingwex/math/llrintl.c
winsup/mingw/mingwex/math/log10f.S
winsup/mingw/mingwex/math/log10l.S
winsup/mingw/mingwex/math/log1p.S
winsup/mingw/mingwex/math/log1pf.S
winsup/mingw/mingwex/math/log1pl.S
winsup/mingw/mingwex/math/log2.S
winsup/mingw/mingwex/math/log2f.S
winsup/mingw/mingwex/math/log2l.S
winsup/mingw/mingwex/math/logb.c
winsup/mingw/mingwex/math/logbf.c
winsup/mingw/mingwex/math/logbl.c
winsup/mingw/mingwex/math/logf.S
winsup/mingw/mingwex/math/logl.S
winsup/mingw/mingwex/math/lrint.c
winsup/mingw/mingwex/math/lrintf.c
winsup/mingw/mingwex/math/lrintl.c
winsup/mingw/mingwex/math/lround_generic.c
winsup/mingw/mingwex/math/modff.c
winsup/mingw/mingwex/math/modfl.c
winsup/mingw/mingwex/math/nearbyint.S
winsup/mingw/mingwex/math/nearbyintf.S
winsup/mingw/mingwex/math/nearbyintl.S
winsup/mingw/mingwex/math/nextafterf.c
winsup/mingw/mingwex/math/nextafterl.c
winsup/mingw/mingwex/math/nexttoward.c
winsup/mingw/mingwex/math/nexttowardf.c
winsup/mingw/mingwex/math/pow.c
winsup/mingw/mingwex/math/powf.c
winsup/mingw/mingwex/math/powi.c
winsup/mingw/mingwex/math/powif.c
winsup/mingw/mingwex/math/powil.c
winsup/mingw/mingwex/math/powl.c
winsup/mingw/mingwex/math/remainder.S
winsup/mingw/mingwex/math/remainderf.S
winsup/mingw/mingwex/math/remainderl.S
winsup/mingw/mingwex/math/remquo.S
winsup/mingw/mingwex/math/remquof.S
winsup/mingw/mingwex/math/remquol.S
winsup/mingw/mingwex/math/rint.c
winsup/mingw/mingwex/math/rintf.c
winsup/mingw/mingwex/math/rintl.c
winsup/mingw/mingwex/math/round_generic.c
winsup/mingw/mingwex/math/round_internal.h
winsup/mingw/mingwex/math/s_erf.c
winsup/mingw/mingwex/math/scalbn.S
winsup/mingw/mingwex/math/scalbnf.S
winsup/mingw/mingwex/math/scalbnl.S
winsup/mingw/mingwex/math/sf_erf.c
winsup/mingw/mingwex/math/signbit.c
winsup/mingw/mingwex/math/signbitf.c
winsup/mingw/mingwex/math/signbitl.c
winsup/mingw/mingwex/math/sinf.S
winsup/mingw/mingwex/math/sinhf.c
winsup/mingw/mingwex/math/sinhl.c
winsup/mingw/mingwex/math/sinl.S
winsup/mingw/mingwex/math/sqrtf.c
winsup/mingw/mingwex/math/sqrtl.c
winsup/mingw/mingwex/math/tanf.S
winsup/mingw/mingwex/math/tanhf.c
winsup/mingw/mingwex/math/tanhl.c
winsup/mingw/mingwex/math/tanl.S
winsup/mingw/mingwex/math/tgamma.c
winsup/mingw/mingwex/math/tgammaf.c
winsup/mingw/mingwex/math/tgammal.c
winsup/mingw/mingwex/math/trunc.c
winsup/mingw/mingwex/math/truncf.c
winsup/mingw/mingwex/math/truncl.c
winsup/mingw/mingwex/mb_wc_common.h
winsup/mingw/mingwex/mbrtowc.c
winsup/mingw/mingwex/mbsinit.c
winsup/mingw/mingwex/mingw-aligned-malloc.c
winsup/mingw/mingwex/mingw-fseek.c
winsup/mingw/mingwex/sitest.c
winsup/mingw/mingwex/stdio/fopen64.c
winsup/mingw/mingwex/stdio/fprintf.c
winsup/mingw/mingwex/stdio/fseeko64.c
winsup/mingw/mingwex/stdio/ftello64.c
winsup/mingw/mingwex/stdio/lseek64.c
winsup/mingw/mingwex/stdio/pformat.c
winsup/mingw/mingwex/stdio/pformat.h
winsup/mingw/mingwex/stdio/printf.c
winsup/mingw/mingwex/stdio/snprintf.c
winsup/mingw/mingwex/stdio/snwprintf.c
winsup/mingw/mingwex/stdio/sprintf.c
winsup/mingw/mingwex/stdio/vfprintf.c
winsup/mingw/mingwex/stdio/vfscanf.c
winsup/mingw/mingwex/stdio/vfwscanf.c
winsup/mingw/mingwex/stdio/vprintf.c
winsup/mingw/mingwex/stdio/vscanf.c
winsup/mingw/mingwex/stdio/vsnprintf.c
winsup/mingw/mingwex/stdio/vsnwprintf.c
winsup/mingw/mingwex/stdio/vsprintf.c
winsup/mingw/mingwex/stdio/vsscanf.c
winsup/mingw/mingwex/stdio/vswscanf.c
winsup/mingw/mingwex/stdio/vwscanf.c
winsup/mingw/mingwex/strtoimax.c
winsup/mingw/mingwex/strtoumax.c
winsup/mingw/mingwex/tdelete.c
winsup/mingw/mingwex/testwmem.c
winsup/mingw/mingwex/tfind.c
winsup/mingw/mingwex/tsearch.c
winsup/mingw/mingwex/tst-aligned-malloc.c
winsup/mingw/mingwex/twalk.c
winsup/mingw/mingwex/ulltoa.c
winsup/mingw/mingwex/ulltow.c
winsup/mingw/mingwex/usleep.c
winsup/mingw/mingwex/wcrtomb.c
winsup/mingw/mingwex/wcstof.c
winsup/mingw/mingwex/wcstoimax.c
winsup/mingw/mingwex/wcstold.c
winsup/mingw/mingwex/wcstoumax.c
winsup/mingw/mingwex/wctob.c
winsup/mingw/mingwex/wctrans.c
winsup/mingw/mingwex/wctype.c
winsup/mingw/mingwex/wdirent.c
winsup/mingw/mingwex/wmemchr.c
winsup/mingw/mingwex/wmemcmp.c
winsup/mingw/mingwex/wmemcpy.c
winsup/mingw/mingwex/wmemmove.c
winsup/mingw/mingwex/wmemset.c
winsup/mingw/mingwex/wtoll.c
winsup/mingw/mkinstalldirs
winsup/mingw/moldname.def.in
winsup/mingw/msvcrt.def.in
winsup/mingw/mthr.c
winsup/mingw/mthr_init.c
winsup/mingw/mthr_stub.c
winsup/mingw/ofmt_stub.s
winsup/mingw/profile/COPYING
winsup/mingw/profile/CYGWIN_LICENSE
winsup/mingw/profile/Makefile.in
winsup/mingw/profile/gcrt0.c
winsup/mingw/profile/gmon.c
winsup/mingw/profile/gmon.h
winsup/mingw/profile/mcount.c
winsup/mingw/profile/profil.c
winsup/mingw/profile/profil.h
winsup/mingw/profile/profile.h
winsup/mingw/pseudo-reloc-list.c
winsup/mingw/pseudo-reloc.c
winsup/mingw/readme.txt
winsup/mingw/samples/dirent/jamfile
winsup/mingw/samples/dirent/test.c
winsup/mingw/samples/dirent/wtest.c
winsup/mingw/samples/dlltest/dll.c
winsup/mingw/samples/dlltest/dll.def
winsup/mingw/samples/dlltest/dll.h
winsup/mingw/samples/dlltest/exe.c
winsup/mingw/samples/dlltest/exe.exp
winsup/mingw/samples/dlltest/expexe.c
winsup/mingw/samples/dlltest/expexe.def
winsup/mingw/samples/dlltest/jamfile
winsup/mingw/samples/dlltest/loaddll.c
winsup/mingw/samples/dlltest/loadexe.c
winsup/mingw/samples/dlltest/readme.txt
winsup/mingw/samples/dlltest/silly.cpp
winsup/mingw/samples/dlltest/silly.def
winsup/mingw/samples/dlltest/silly.exp
winsup/mingw/samples/dlltest/silly.h
winsup/mingw/samples/dlltest/sillydll.cpp
winsup/mingw/samples/filehand/filehand.c
winsup/mingw/samples/filehand/jamfile
winsup/mingw/samples/filehand/junk.txt
winsup/mingw/samples/fixargv/fixargv.c
winsup/mingw/samples/fixargv/fixargv.h
winsup/mingw/samples/fixargv/readme.txt
winsup/mingw/samples/fmode/all.c
winsup/mingw/samples/fmode/jamfile
winsup/mingw/samples/fmode/readme.txt
winsup/mingw/samples/fmode/test.c
winsup/mingw/samples/fmode/test2.c
winsup/mingw/samples/globbing/glob.c
winsup/mingw/samples/globbing/jamfile
winsup/mingw/samples/globbing/noglob.c
winsup/mingw/samples/globbing/readme.txt
winsup/mingw/samples/print/jamfile
winsup/mingw/samples/print/prntest.c
winsup/mingw/samples/seh/eh3.c
winsup/mingw/samples/seh/exutil.c
winsup/mingw/samples/seh/exutil.def
winsup/mingw/samples/seh/exutil.h
winsup/mingw/samples/seh/jamfile
winsup/mingw/samples/seh/sehfix.c
winsup/mingw/samples/seh/sehsub.c
winsup/mingw/samples/seh/sehtest.c
winsup/mingw/samples/simpledll/dll.c
winsup/mingw/samples/simpledll/dll.cpp
winsup/mingw/samples/simpledll/dll.def
winsup/mingw/samples/simpledll/exe.c
winsup/mingw/samples/simpledll/jamfile
winsup/mingw/samples/simpledll/makedll.bat
winsup/mingw/samples/test/jamfile
winsup/mingw/samples/test/test.c
winsup/mingw/samples/wintest/jamfile
winsup/mingw/samples/wintest/test.c
winsup/mingw/strcasecmp.c
winsup/mingw/strncasecmp.c
winsup/mingw/test_headers.c
winsup/mingw/toascii.c
winsup/mingw/txtmode.c
winsup/mingw/wcscmpi.c
winsup/testsuite/ChangeLog
winsup/testsuite/Makefile.in
winsup/testsuite/README
winsup/testsuite/aclocal.m4
winsup/testsuite/config/default.exp
winsup/testsuite/configure
winsup/testsuite/configure.in
winsup/testsuite/cygrun.c
winsup/testsuite/libltp/include/dataascii.h
winsup/testsuite/libltp/include/databin.h
winsup/testsuite/libltp/include/file_lock.h
winsup/testsuite/libltp/include/forker.h
winsup/testsuite/libltp/include/open_flags.h
winsup/testsuite/libltp/include/pattern.h
winsup/testsuite/libltp/include/random_range.h
winsup/testsuite/libltp/include/rmobj.h
winsup/testsuite/libltp/include/search_path.h
winsup/testsuite/libltp/include/str_to_bytes.h
winsup/testsuite/libltp/include/string_to_tokens.h
winsup/testsuite/libltp/include/test.h
winsup/testsuite/libltp/include/tlibio.h
winsup/testsuite/libltp/include/usctest.h
winsup/testsuite/libltp/include/write_log.h
winsup/testsuite/libltp/lib/dataascii.c
winsup/testsuite/libltp/lib/databin.c
winsup/testsuite/libltp/lib/datapid.c
winsup/testsuite/libltp/lib/forker.c
winsup/testsuite/libltp/lib/get_high_address.c
winsup/testsuite/libltp/lib/libtestsuite.c
winsup/testsuite/libltp/lib/open_flags.c
winsup/testsuite/libltp/lib/parse_opts.c
winsup/testsuite/libltp/lib/pattern.c
winsup/testsuite/libltp/lib/rmobj.c
winsup/testsuite/libltp/lib/search_path.c
winsup/testsuite/libltp/lib/str_to_bytes.c
winsup/testsuite/libltp/lib/string_to_tokens.c
winsup/testsuite/libltp/lib/tst_res.c
winsup/testsuite/libltp/lib/tst_sig.c
winsup/testsuite/libltp/lib/tst_tmpdir.c
winsup/testsuite/libltp/lib/write_log.c
winsup/testsuite/winsup.api/checksignal.c
winsup/testsuite/winsup.api/crlf.c
winsup/testsuite/winsup.api/cygload.cc
winsup/testsuite/winsup.api/cygload.exp
winsup/testsuite/winsup.api/cygload.h
winsup/testsuite/winsup.api/devdsp.c
winsup/testsuite/winsup.api/devdsp_okay.h
winsup/testsuite/winsup.api/devzero.c
winsup/testsuite/winsup.api/iospeed.c
winsup/testsuite/winsup.api/known_bugs.tcl
winsup/testsuite/winsup.api/ltp/access01.c
winsup/testsuite/winsup.api/ltp/access03.c
winsup/testsuite/winsup.api/ltp/access04.c
winsup/testsuite/winsup.api/ltp/access05.c
winsup/testsuite/winsup.api/ltp/alarm01.c
winsup/testsuite/winsup.api/ltp/alarm02.c
winsup/testsuite/winsup.api/ltp/alarm03.c
winsup/testsuite/winsup.api/ltp/alarm07.c
winsup/testsuite/winsup.api/ltp/asyncio02.c
winsup/testsuite/winsup.api/ltp/chdir02.c
winsup/testsuite/winsup.api/ltp/chdir04.c
winsup/testsuite/winsup.api/ltp/chmod01.c
winsup/testsuite/winsup.api/ltp/chmod02.c
winsup/testsuite/winsup.api/ltp/chown01.c
winsup/testsuite/winsup.api/ltp/close01.c
winsup/testsuite/winsup.api/ltp/close02.c
winsup/testsuite/winsup.api/ltp/close08.c
winsup/testsuite/winsup.api/ltp/creat01.c
winsup/testsuite/winsup.api/ltp/creat03.c
winsup/testsuite/winsup.api/ltp/creat09.c
winsup/testsuite/winsup.api/ltp/dup01.c
winsup/testsuite/winsup.api/ltp/dup02.c
winsup/testsuite/winsup.api/ltp/dup03.c
winsup/testsuite/winsup.api/ltp/dup04.c
winsup/testsuite/winsup.api/ltp/dup05.c
winsup/testsuite/winsup.api/ltp/execl01.c
winsup/testsuite/winsup.api/ltp/execle01.c
winsup/testsuite/winsup.api/ltp/execlp01.c
winsup/testsuite/winsup.api/ltp/execv01.c
winsup/testsuite/winsup.api/ltp/execve01.c
winsup/testsuite/winsup.api/ltp/execvp01.c
winsup/testsuite/winsup.api/ltp/exit01.c
winsup/testsuite/winsup.api/ltp/exit02.c
winsup/testsuite/winsup.api/ltp/fchdir01.c
winsup/testsuite/winsup.api/ltp/fchdir02.c
winsup/testsuite/winsup.api/ltp/fchmod01.c
winsup/testsuite/winsup.api/ltp/fchown01.c
winsup/testsuite/winsup.api/ltp/fcntl02.c
winsup/testsuite/winsup.api/ltp/fcntl03.c
winsup/testsuite/winsup.api/ltp/fcntl04.c
winsup/testsuite/winsup.api/ltp/fcntl05.c
winsup/testsuite/winsup.api/ltp/fcntl07.c
winsup/testsuite/winsup.api/ltp/fcntl07B.c
winsup/testsuite/winsup.api/ltp/fcntl08.c
winsup/testsuite/winsup.api/ltp/fcntl09.c
winsup/testsuite/winsup.api/ltp/fcntl10.c
winsup/testsuite/winsup.api/ltp/fork01.c
winsup/testsuite/winsup.api/ltp/fork02.c
winsup/testsuite/winsup.api/ltp/fork03.c
winsup/testsuite/winsup.api/ltp/fork04.c
winsup/testsuite/winsup.api/ltp/fork06.c
winsup/testsuite/winsup.api/ltp/fork07.c
winsup/testsuite/winsup.api/ltp/fork09.c
winsup/testsuite/winsup.api/ltp/fork10.c
winsup/testsuite/winsup.api/ltp/fork11.c
winsup/testsuite/winsup.api/ltp/fpathconf01.c
winsup/testsuite/winsup.api/ltp/fstat01.c
winsup/testsuite/winsup.api/ltp/fstat02.c
winsup/testsuite/winsup.api/ltp/fstat03.c
winsup/testsuite/winsup.api/ltp/fstat04.c
winsup/testsuite/winsup.api/ltp/fsync01.c
winsup/testsuite/winsup.api/ltp/ftruncate01.c
winsup/testsuite/winsup.api/ltp/ftruncate02.c
winsup/testsuite/winsup.api/ltp/ftruncate03.c
winsup/testsuite/winsup.api/ltp/getegid01.c
winsup/testsuite/winsup.api/ltp/geteuid01.c
winsup/testsuite/winsup.api/ltp/getgid01.c
winsup/testsuite/winsup.api/ltp/getgid02.c
winsup/testsuite/winsup.api/ltp/getgid03.c
winsup/testsuite/winsup.api/ltp/getgroups01.c
winsup/testsuite/winsup.api/ltp/getgroups02.c
winsup/testsuite/winsup.api/ltp/gethostid01.c
winsup/testsuite/winsup.api/ltp/gethostname01.c
winsup/testsuite/winsup.api/ltp/getpgid01.c
winsup/testsuite/winsup.api/ltp/getpgid02.c
winsup/testsuite/winsup.api/ltp/getpgrp01.c
winsup/testsuite/winsup.api/ltp/getpid01.c
winsup/testsuite/winsup.api/ltp/getpid02.c
winsup/testsuite/winsup.api/ltp/getppid01.c
winsup/testsuite/winsup.api/ltp/getppid02.c
winsup/testsuite/winsup.api/ltp/getuid01.c
winsup/testsuite/winsup.api/ltp/getuid02.c
winsup/testsuite/winsup.api/ltp/getuid03.c
winsup/testsuite/winsup.api/ltp/kill01.c
winsup/testsuite/winsup.api/ltp/kill02.c
winsup/testsuite/winsup.api/ltp/kill03.c
winsup/testsuite/winsup.api/ltp/kill04.c
winsup/testsuite/winsup.api/ltp/kill09.c
winsup/testsuite/winsup.api/ltp/link02.c
winsup/testsuite/winsup.api/ltp/link03.c
winsup/testsuite/winsup.api/ltp/link04.c
winsup/testsuite/winsup.api/ltp/link05.c
winsup/testsuite/winsup.api/ltp/lseek01.c
winsup/testsuite/winsup.api/ltp/lseek02.c
winsup/testsuite/winsup.api/ltp/lseek03.c
winsup/testsuite/winsup.api/ltp/lseek04.c
winsup/testsuite/winsup.api/ltp/lseek05.c
winsup/testsuite/winsup.api/ltp/lseek06.c
winsup/testsuite/winsup.api/ltp/lseek07.c
winsup/testsuite/winsup.api/ltp/lseek08.c
winsup/testsuite/winsup.api/ltp/lseek09.c
winsup/testsuite/winsup.api/ltp/lseek10.c
winsup/testsuite/winsup.api/ltp/lstat02.c
winsup/testsuite/winsup.api/ltp/mkdir01.c
winsup/testsuite/winsup.api/ltp/mkdir08.c
winsup/testsuite/winsup.api/ltp/mknod01.c
winsup/testsuite/winsup.api/ltp/mmap001.c
winsup/testsuite/winsup.api/ltp/mmap02.c
winsup/testsuite/winsup.api/ltp/mmap03.c
winsup/testsuite/winsup.api/ltp/mmap04.c
winsup/testsuite/winsup.api/ltp/mmap05.c
winsup/testsuite/winsup.api/ltp/mmap06.c
winsup/testsuite/winsup.api/ltp/mmap07.c
winsup/testsuite/winsup.api/ltp/mmap08.c
winsup/testsuite/winsup.api/ltp/munmap01.c
winsup/testsuite/winsup.api/ltp/munmap02.c
winsup/testsuite/winsup.api/ltp/nice05.c
winsup/testsuite/winsup.api/ltp/open02.c
winsup/testsuite/winsup.api/ltp/open03.c
winsup/testsuite/winsup.api/ltp/pathconf01.c
winsup/testsuite/winsup.api/ltp/pause01.c
winsup/testsuite/winsup.api/ltp/pipe01.c
winsup/testsuite/winsup.api/ltp/pipe08.c
winsup/testsuite/winsup.api/ltp/pipe09.c
winsup/testsuite/winsup.api/ltp/pipe10.c
winsup/testsuite/winsup.api/ltp/pipe11.c
winsup/testsuite/winsup.api/ltp/poll01.c
winsup/testsuite/winsup.api/ltp/read01.c
winsup/testsuite/winsup.api/ltp/read04.c
winsup/testsuite/winsup.api/ltp/readdir01.c
winsup/testsuite/winsup.api/ltp/readlink01.c
winsup/testsuite/winsup.api/ltp/readlink02.c
winsup/testsuite/winsup.api/ltp/readlink03.c
winsup/testsuite/winsup.api/ltp/rename01.c
winsup/testsuite/winsup.api/ltp/rename02.c
winsup/testsuite/winsup.api/ltp/rename08.c
winsup/testsuite/winsup.api/ltp/rename10.c
winsup/testsuite/winsup.api/ltp/rmdir01.c
winsup/testsuite/winsup.api/ltp/rmdir04.c
winsup/testsuite/winsup.api/ltp/rmdir05.c
winsup/testsuite/winsup.api/ltp/sbrk01.c
winsup/testsuite/winsup.api/ltp/select01.c
winsup/testsuite/winsup.api/ltp/select02.c
winsup/testsuite/winsup.api/ltp/select03.c
winsup/testsuite/winsup.api/ltp/setgid01.c
winsup/testsuite/winsup.api/ltp/setgroups01.c
winsup/testsuite/winsup.api/ltp/setpgid01.c
winsup/testsuite/winsup.api/ltp/setregid01.c
winsup/testsuite/winsup.api/ltp/setreuid01.c
winsup/testsuite/winsup.api/ltp/setuid01.c
winsup/testsuite/winsup.api/ltp/setuid02.c
winsup/testsuite/winsup.api/ltp/signal03.c
winsup/testsuite/winsup.api/ltp/stat01.c
winsup/testsuite/winsup.api/ltp/stat02.c
winsup/testsuite/winsup.api/ltp/stat03.c
winsup/testsuite/winsup.api/ltp/stat05.c
winsup/testsuite/winsup.api/ltp/stat06.c
winsup/testsuite/winsup.api/ltp/symlink01.c
winsup/testsuite/winsup.api/ltp/symlink02.c
winsup/testsuite/winsup.api/ltp/symlink03.c
winsup/testsuite/winsup.api/ltp/symlink04.c
winsup/testsuite/winsup.api/ltp/symlink05.c
winsup/testsuite/winsup.api/ltp/sync01.c
winsup/testsuite/winsup.api/ltp/sync02.c
winsup/testsuite/winsup.api/ltp/time01.c
winsup/testsuite/winsup.api/ltp/time02.c
winsup/testsuite/winsup.api/ltp/times01.c
winsup/testsuite/winsup.api/ltp/times02.c
winsup/testsuite/winsup.api/ltp/times03.c
winsup/testsuite/winsup.api/ltp/truncate01.c
winsup/testsuite/winsup.api/ltp/truncate02.c
winsup/testsuite/winsup.api/ltp/ulimit01.c
winsup/testsuite/winsup.api/ltp/umask01.c
winsup/testsuite/winsup.api/ltp/umask02.c
winsup/testsuite/winsup.api/ltp/umask03.c
winsup/testsuite/winsup.api/ltp/uname01.c
winsup/testsuite/winsup.api/ltp/unlink05.c
winsup/testsuite/winsup.api/ltp/unlink06.c
winsup/testsuite/winsup.api/ltp/unlink07.c
winsup/testsuite/winsup.api/ltp/unlink08.c
winsup/testsuite/winsup.api/ltp/vfork01.c
winsup/testsuite/winsup.api/ltp/wait02.c
winsup/testsuite/winsup.api/ltp/wait401.c
winsup/testsuite/winsup.api/ltp/wait402.c
winsup/testsuite/winsup.api/ltp/write01.c
winsup/testsuite/winsup.api/ltp/write02.c
winsup/testsuite/winsup.api/ltp/write03.c
winsup/testsuite/winsup.api/mmaptest01.c
winsup/testsuite/winsup.api/mmaptest02.c
winsup/testsuite/winsup.api/mmaptest03.c
winsup/testsuite/winsup.api/mmaptest04.c
winsup/testsuite/winsup.api/msgtest.c
winsup/testsuite/winsup.api/nullgetcwd.c
winsup/testsuite/winsup.api/pthread/cancel1.c
winsup/testsuite/winsup.api/pthread/cancel10.c
winsup/testsuite/winsup.api/pthread/cancel11.c
winsup/testsuite/winsup.api/pthread/cancel12.c
winsup/testsuite/winsup.api/pthread/cancel2.c
winsup/testsuite/winsup.api/pthread/cancel3.c
winsup/testsuite/winsup.api/pthread/cancel4.c
winsup/testsuite/winsup.api/pthread/cancel5.c
winsup/testsuite/winsup.api/pthread/cancel6.c
winsup/testsuite/winsup.api/pthread/cancel7.c
winsup/testsuite/winsup.api/pthread/cancel8.c
winsup/testsuite/winsup.api/pthread/cancel9.c
winsup/testsuite/winsup.api/pthread/cleanup2.c
winsup/testsuite/winsup.api/pthread/cleanup3.c
winsup/testsuite/winsup.api/pthread/condvar1.c
winsup/testsuite/winsup.api/pthread/condvar2.c
winsup/testsuite/winsup.api/pthread/condvar2_1.c
winsup/testsuite/winsup.api/pthread/condvar3.c
winsup/testsuite/winsup.api/pthread/condvar3_1.c
winsup/testsuite/winsup.api/pthread/condvar3_2.c
winsup/testsuite/winsup.api/pthread/condvar3_3.c
winsup/testsuite/winsup.api/pthread/condvar4.c
winsup/testsuite/winsup.api/pthread/condvar5.c
winsup/testsuite/winsup.api/pthread/condvar6.c
winsup/testsuite/winsup.api/pthread/condvar7.c
winsup/testsuite/winsup.api/pthread/condvar8.c
winsup/testsuite/winsup.api/pthread/condvar9.c
winsup/testsuite/winsup.api/pthread/count1.c
winsup/testsuite/winsup.api/pthread/create1.c
winsup/testsuite/winsup.api/pthread/create2.c
winsup/testsuite/winsup.api/pthread/equal1.c
winsup/testsuite/winsup.api/pthread/exit1.c
winsup/testsuite/winsup.api/pthread/exit2.c
winsup/testsuite/winsup.api/pthread/exit3.c
winsup/testsuite/winsup.api/pthread/inherit1.c
winsup/testsuite/winsup.api/pthread/join0.c
winsup/testsuite/winsup.api/pthread/join1.c
winsup/testsuite/winsup.api/pthread/join2.c
winsup/testsuite/winsup.api/pthread/mainthreadexits.c
winsup/testsuite/winsup.api/pthread/mutex1.c
winsup/testsuite/winsup.api/pthread/mutex1d.c
winsup/testsuite/winsup.api/pthread/mutex1e.c
winsup/testsuite/winsup.api/pthread/mutex1n.c
winsup/testsuite/winsup.api/pthread/mutex1r.c
winsup/testsuite/winsup.api/pthread/mutex2.c
winsup/testsuite/winsup.api/pthread/mutex3.c
winsup/testsuite/winsup.api/pthread/mutex4.c
winsup/testsuite/winsup.api/pthread/mutex5.c
winsup/testsuite/winsup.api/pthread/mutex6d.c
winsup/testsuite/winsup.api/pthread/mutex6e.c
winsup/testsuite/winsup.api/pthread/mutex6n.c
winsup/testsuite/winsup.api/pthread/mutex6r.c
winsup/testsuite/winsup.api/pthread/mutex7.c
winsup/testsuite/winsup.api/pthread/mutex7d.c
winsup/testsuite/winsup.api/pthread/mutex7e.c
winsup/testsuite/winsup.api/pthread/mutex7n.c
winsup/testsuite/winsup.api/pthread/mutex7r.c
winsup/testsuite/winsup.api/pthread/mutex8e.c
winsup/testsuite/winsup.api/pthread/mutex8n.c
winsup/testsuite/winsup.api/pthread/mutex8r.c
winsup/testsuite/winsup.api/pthread/once1.c
winsup/testsuite/winsup.api/pthread/priority1.c
winsup/testsuite/winsup.api/pthread/priority2.c
winsup/testsuite/winsup.api/pthread/rwlock1.c
winsup/testsuite/winsup.api/pthread/rwlock2.c
winsup/testsuite/winsup.api/pthread/rwlock3.c
winsup/testsuite/winsup.api/pthread/rwlock4.c
winsup/testsuite/winsup.api/pthread/rwlock5.c
winsup/testsuite/winsup.api/pthread/rwlock6.c
winsup/testsuite/winsup.api/pthread/rwlock7.c
winsup/testsuite/winsup.api/pthread/self1.c
winsup/testsuite/winsup.api/pthread/self2.c
winsup/testsuite/winsup.api/pthread/test.h
winsup/testsuite/winsup.api/pthread/threadidafterfork.c
winsup/testsuite/winsup.api/pthread/tsd1.c
winsup/testsuite/winsup.api/resethand.c
winsup/testsuite/winsup.api/samples/sample-fail.c
winsup/testsuite/winsup.api/samples/sample-miscompile.c
winsup/testsuite/winsup.api/samples/sample-pass.c
winsup/testsuite/winsup.api/semtest.c
winsup/testsuite/winsup.api/shmtest.c
winsup/testsuite/winsup.api/sigchld.c
winsup/testsuite/winsup.api/signal-into-win32-api.c
winsup/testsuite/winsup.api/systemcall.c
winsup/testsuite/winsup.api/user_malloc.c
winsup/testsuite/winsup.api/waitpid.c
winsup/testsuite/winsup.api/winsup.exp
winsup/utils/COPYING.dumper
winsup/utils/ChangeLog
winsup/utils/ChangeLog-2000
winsup/utils/Makefile.in
winsup/utils/aclocal.m4
winsup/utils/bloda.cc
winsup/utils/configure
winsup/utils/configure.in
winsup/utils/cygcheck.cc
winsup/utils/cygpath.cc
winsup/utils/cygwin-console-helper.cc
winsup/utils/dump_setup.cc
winsup/utils/dumper.cc
winsup/utils/dumper.h
winsup/utils/getfacl.c
winsup/utils/kill.cc
winsup/utils/ldd.cc
winsup/utils/ldh.cc
winsup/utils/mingw
winsup/utils/mkgroup.c
winsup/utils/mkpasswd.c
winsup/utils/module_info.cc
winsup/utils/mount.cc
winsup/utils/parse_pe.cc
winsup/utils/passwd.c
winsup/utils/path.cc
winsup/utils/path.h
winsup/utils/ps.cc
winsup/utils/regtool.cc
winsup/utils/setfacl.c
winsup/utils/setmetamode.c
winsup/utils/ssp.c
winsup/utils/ssp.txt
winsup/utils/strace.cc
winsup/utils/testsuite.cc
winsup/utils/testsuite.h
winsup/utils/umount.cc
winsup/utils/utils.sgml
winsup/utils/wide_path.h
winsup/w32api/CONTRIBUTIONS
winsup/w32api/ChangeLog
winsup/w32api/Makefile.in
winsup/w32api/README.w32api
winsup/w32api/TODO
winsup/w32api/aclocal.m4
winsup/w32api/config.guess
winsup/w32api/config.sub
winsup/w32api/configure
winsup/w32api/configure.in
winsup/w32api/include/GL/gl.h
winsup/w32api/include/GL/glext.h
winsup/w32api/include/GL/glu.h
winsup/w32api/include/accctrl.h
winsup/w32api/include/aclapi.h
winsup/w32api/include/aclui.h
winsup/w32api/include/adsprop.h
winsup/w32api/include/afxres.h
winsup/w32api/include/amaudio.h
winsup/w32api/include/amvideo.h
winsup/w32api/include/audevcod.h
winsup/w32api/include/aviriff.h
winsup/w32api/include/aygshell.h
winsup/w32api/include/basetsd.h
winsup/w32api/include/basetyps.h
winsup/w32api/include/bdatypes.h
winsup/w32api/include/cderr.h
winsup/w32api/include/cguid.h
winsup/w32api/include/cmnquery.h
winsup/w32api/include/comcat.h
winsup/w32api/include/commctrl.h
winsup/w32api/include/commdlg.h
winsup/w32api/include/control.h
winsup/w32api/include/cpl.h
winsup/w32api/include/cplext.h
winsup/w32api/include/custcntl.h
winsup/w32api/include/dbt.h
winsup/w32api/include/dde.h
winsup/w32api/include/ddeml.h
winsup/w32api/include/ddk/atm.h
winsup/w32api/include/ddk/batclass.h
winsup/w32api/include/ddk/cfg.h
winsup/w32api/include/ddk/cfgmgr32.h
winsup/w32api/include/ddk/d4drvif.h
winsup/w32api/include/ddk/d4iface.h
winsup/w32api/include/ddk/ddkmapi.h
winsup/w32api/include/ddk/hidclass.h
winsup/w32api/include/ddk/hidpi.h
winsup/w32api/include/ddk/hidsdi.h
winsup/w32api/include/ddk/hidusage.h
winsup/w32api/include/ddk/kbdmou.h
winsup/w32api/include/ddk/mcd.h
winsup/w32api/include/ddk/miniport.h
winsup/w32api/include/ddk/minitape.h
winsup/w32api/include/ddk/mountdev.h
winsup/w32api/include/ddk/mountmgr.h
winsup/w32api/include/ddk/ndis.h
winsup/w32api/include/ddk/ndisguid.h
winsup/w32api/include/ddk/ndistapi.h
winsup/w32api/include/ddk/ndiswan.h
winsup/w32api/include/ddk/netevent.h
winsup/w32api/include/ddk/netpnp.h
winsup/w32api/include/ddk/newdev.h
winsup/w32api/include/ddk/ntapi.h
winsup/w32api/include/ddk/ntdd8042.h
winsup/w32api/include/ddk/ntddbeep.h
winsup/w32api/include/ddk/ntddcdrm.h
winsup/w32api/include/ddk/ntddcdvd.h
winsup/w32api/include/ddk/ntddchgr.h
winsup/w32api/include/ddk/ntdddisk.h
winsup/w32api/include/ddk/ntddk.h
winsup/w32api/include/ddk/ntddkbd.h
winsup/w32api/include/ddk/ntddmou.h
winsup/w32api/include/ddk/ntddndis.h
winsup/w32api/include/ddk/ntddpar.h
winsup/w32api/include/ddk/ntddpcm.h
winsup/w32api/include/ddk/ntddscsi.h
winsup/w32api/include/ddk/ntddser.h
winsup/w32api/include/ddk/ntddstor.h
winsup/w32api/include/ddk/ntddtape.h
winsup/w32api/include/ddk/ntddtdi.h
winsup/w32api/include/ddk/ntddvdeo.h
winsup/w32api/include/ddk/ntddvol.h
winsup/w32api/include/ddk/ntifs.h
winsup/w32api/include/ddk/ntpoapi.h
winsup/w32api/include/ddk/ntstatus.h
winsup/w32api/include/ddk/parallel.h
winsup/w32api/include/ddk/pfhook.h
winsup/w32api/include/ddk/poclass.h
winsup/w32api/include/ddk/scsi.h
winsup/w32api/include/ddk/scsiscan.h
winsup/w32api/include/ddk/scsiwmi.h
winsup/w32api/include/ddk/smbus.h
winsup/w32api/include/ddk/srb.h
winsup/w32api/include/ddk/storport.h
winsup/w32api/include/ddk/tdi.h
winsup/w32api/include/ddk/tdiinfo.h
winsup/w32api/include/ddk/tdikrnl.h
winsup/w32api/include/ddk/tdistat.h
winsup/w32api/include/ddk/tvout.h
winsup/w32api/include/ddk/upssvc.h
winsup/w32api/include/ddk/usb.h
winsup/w32api/include/ddk/usb100.h
winsup/w32api/include/ddk/usbcamdi.h
winsup/w32api/include/ddk/usbdi.h
winsup/w32api/include/ddk/usbioctl.h
winsup/w32api/include/ddk/usbiodef.h
winsup/w32api/include/ddk/usbscan.h
winsup/w32api/include/ddk/usbuser.h
winsup/w32api/include/ddk/video.h
winsup/w32api/include/ddk/videoagp.h
winsup/w32api/include/ddk/win2k.h
winsup/w32api/include/ddk/winddi.h
winsup/w32api/include/ddk/winddk.h
winsup/w32api/include/ddk/winnt4.h
winsup/w32api/include/ddk/winxp.h
winsup/w32api/include/ddk/ws2san.h
winsup/w32api/include/ddk/xfilter.h
winsup/w32api/include/devguid.h
winsup/w32api/include/dhcpcsdk.h
winsup/w32api/include/directx/d3d9.h
winsup/w32api/include/directx/d3d9caps.h
winsup/w32api/include/directx/d3d9types.h
winsup/w32api/include/directx/dxerr8.h
winsup/w32api/include/directx/dxerr9.h
winsup/w32api/include/dlgs.h
winsup/w32api/include/docobj.h
winsup/w32api/include/dsadmin.h
winsup/w32api/include/dsclient.h
winsup/w32api/include/dsgetdc.h
winsup/w32api/include/dshow.h
winsup/w32api/include/dsquery.h
winsup/w32api/include/dsrole.h
winsup/w32api/include/dvdevcod.h
winsup/w32api/include/dvdmedia.h
winsup/w32api/include/edevdefs.h
winsup/w32api/include/errorrep.h
winsup/w32api/include/errors.h
winsup/w32api/include/evcode.h
winsup/w32api/include/exdisp.h
winsup/w32api/include/exdispid.h
winsup/w32api/include/fltdefs.h
winsup/w32api/include/httpext.h
winsup/w32api/include/icm.h
winsup/w32api/include/idispids.h
winsup/w32api/include/il21dec.h
winsup/w32api/include/imagehlp.h
winsup/w32api/include/imm.h
winsup/w32api/include/initguid.h
winsup/w32api/include/intshcut.h
winsup/w32api/include/ipexport.h
winsup/w32api/include/iphlpapi.h
winsup/w32api/include/ipifcons.h
winsup/w32api/include/ipinfoid.h
winsup/w32api/include/iprtrmib.h
winsup/w32api/include/iptypes.h
winsup/w32api/include/ipxconst.h
winsup/w32api/include/ipxrtdef.h
winsup/w32api/include/ipxtfflt.h
winsup/w32api/include/isguids.h
winsup/w32api/include/ks.h
winsup/w32api/include/ksmedia.h
winsup/w32api/include/largeint.h
winsup/w32api/include/lm.h
winsup/w32api/include/lmaccess.h
winsup/w32api/include/lmalert.h
winsup/w32api/include/lmapibuf.h
winsup/w32api/include/lmat.h
winsup/w32api/include/lmaudit.h
winsup/w32api/include/lmbrowsr.h
winsup/w32api/include/lmchdev.h
winsup/w32api/include/lmconfig.h
winsup/w32api/include/lmcons.h
winsup/w32api/include/lmerr.h
winsup/w32api/include/lmerrlog.h
winsup/w32api/include/lmmsg.h
winsup/w32api/include/lmremutl.h
winsup/w32api/include/lmrepl.h
winsup/w32api/include/lmserver.h
winsup/w32api/include/lmshare.h
winsup/w32api/include/lmsname.h
winsup/w32api/include/lmstats.h
winsup/w32api/include/lmsvc.h
winsup/w32api/include/lmuse.h
winsup/w32api/include/lmuseflg.h
winsup/w32api/include/lmwksta.h
winsup/w32api/include/lzexpand.h
winsup/w32api/include/mapi.h
winsup/w32api/include/mciavi.h
winsup/w32api/include/mcx.h
winsup/w32api/include/mgm.h
winsup/w32api/include/mgmtapi.h
winsup/w32api/include/mlang.h
winsup/w32api/include/mmreg.h
winsup/w32api/include/mmsystem.h
winsup/w32api/include/mpegtype.h
winsup/w32api/include/mprapi.h
winsup/w32api/include/mq.h
winsup/w32api/include/msacm.h
winsup/w32api/include/mshtml.h
winsup/w32api/include/mswsock.h
winsup/w32api/include/nb30.h
winsup/w32api/include/nddeapi.h
winsup/w32api/include/nspapi.h
winsup/w32api/include/ntdef.h
winsup/w32api/include/ntdll.h
winsup/w32api/include/ntdsapi.h
winsup/w32api/include/ntdsbcli.h
winsup/w32api/include/ntldap.h
winsup/w32api/include/ntsecapi.h
winsup/w32api/include/ntsecpkg.h
winsup/w32api/include/oaidl.h
winsup/w32api/include/objbase.h
winsup/w32api/include/objfwd.h
winsup/w32api/include/objidl.h
winsup/w32api/include/objsafe.h
winsup/w32api/include/objsel.h
winsup/w32api/include/ocidl.h
winsup/w32api/include/odbcinst.h
winsup/w32api/include/ole.h
winsup/w32api/include/ole2.h
winsup/w32api/include/ole2ver.h
winsup/w32api/include/oleacc.h
winsup/w32api/include/oleauto.h
winsup/w32api/include/olectl.h
winsup/w32api/include/olectlid.h
winsup/w32api/include/oledlg.h
winsup/w32api/include/oleidl.h
winsup/w32api/include/pbt.h
winsup/w32api/include/poppack.h
winsup/w32api/include/powrprof.h
winsup/w32api/include/prsht.h
winsup/w32api/include/psapi.h
winsup/w32api/include/pshpack1.h
winsup/w32api/include/pshpack2.h
winsup/w32api/include/pshpack4.h
winsup/w32api/include/pshpack8.h
winsup/w32api/include/qedit.h
winsup/w32api/include/rapi.h
winsup/w32api/include/ras.h
winsup/w32api/include/rasdlg.h
winsup/w32api/include/raserror.h
winsup/w32api/include/rassapi.h
winsup/w32api/include/reason.h
winsup/w32api/include/regstr.h
winsup/w32api/include/richedit.h
winsup/w32api/include/richole.h
winsup/w32api/include/routprot.h
winsup/w32api/include/rpc.h
winsup/w32api/include/rpcdce.h
winsup/w32api/include/rpcdce2.h
winsup/w32api/include/rpcdcep.h
winsup/w32api/include/rpcndr.h
winsup/w32api/include/rpcnsi.h
winsup/w32api/include/rpcnsip.h
winsup/w32api/include/rpcnterr.h
winsup/w32api/include/rpcproxy.h
winsup/w32api/include/rtutils.h
winsup/w32api/include/schannel.h
winsup/w32api/include/schnlsp.h
winsup/w32api/include/scrnsave.h
winsup/w32api/include/sddl.h
winsup/w32api/include/secext.h
winsup/w32api/include/security.h
winsup/w32api/include/servprov.h
winsup/w32api/include/setupapi.h
winsup/w32api/include/shellapi.h
winsup/w32api/include/shldisp.h
winsup/w32api/include/shlguid.h
winsup/w32api/include/shlobj.h
winsup/w32api/include/shlwapi.h
winsup/w32api/include/snmp.h
winsup/w32api/include/specstrings.h
winsup/w32api/include/sql.h
winsup/w32api/include/sqlext.h
winsup/w32api/include/sqltypes.h
winsup/w32api/include/sqlucode.h
winsup/w32api/include/sspi.h
winsup/w32api/include/stm.h
winsup/w32api/include/strmif.h
winsup/w32api/include/subauth.h
winsup/w32api/include/svcguid.h
winsup/w32api/include/tlhelp32.h
winsup/w32api/include/tmschema.h
winsup/w32api/include/unknwn.h
winsup/w32api/include/userenv.h
winsup/w32api/include/usp10.h
winsup/w32api/include/uxtheme.h
winsup/w32api/include/vfw.h
winsup/w32api/include/vidcap.h
winsup/w32api/include/vmr9.h
winsup/w32api/include/vptype.h
winsup/w32api/include/w32api.h
winsup/w32api/include/winable.h
winsup/w32api/include/winbase.h
winsup/w32api/include/winber.h
winsup/w32api/include/wincon.h
winsup/w32api/include/wincrypt.h
winsup/w32api/include/windef.h
winsup/w32api/include/windns.h
winsup/w32api/include/windows.h
winsup/w32api/include/windowsx.h
winsup/w32api/include/winerror.h
winsup/w32api/include/wingdi.h
winsup/w32api/include/wininet.h
winsup/w32api/include/winioctl.h
winsup/w32api/include/winldap.h
winsup/w32api/include/winnetwk.h
winsup/w32api/include/winnls.h
winsup/w32api/include/winnt.h
winsup/w32api/include/winperf.h
winsup/w32api/include/winreg.h
winsup/w32api/include/winresrc.h
winsup/w32api/include/winsnmp.h
winsup/w32api/include/winsock.h
winsup/w32api/include/winsock2.h
winsup/w32api/include/winspool.h
winsup/w32api/include/winsvc.h
winsup/w32api/include/winuser.h
winsup/w32api/include/winver.h
winsup/w32api/include/ws2spi.h
winsup/w32api/include/ws2tcpip.h
winsup/w32api/include/wsahelp.h
winsup/w32api/include/wsipx.h
winsup/w32api/include/wsnetbs.h
winsup/w32api/include/wtsapi32.h
winsup/w32api/include/wtypes.h
winsup/w32api/include/xprtdefs.h
winsup/w32api/include/zmouse.h
winsup/w32api/install-sh
winsup/w32api/lib/Makefile.in
winsup/w32api/lib/aclui.def
winsup/w32api/lib/advapi32.def
winsup/w32api/lib/ativscp-uuid.c
winsup/w32api/lib/avicap32.def
winsup/w32api/lib/avifil32.def
winsup/w32api/lib/bthprops.def
winsup/w32api/lib/cap.def
winsup/w32api/lib/cguid-uuid.c
winsup/w32api/lib/comcat-uuid.c
winsup/w32api/lib/comctl32.def
winsup/w32api/lib/comdlg32.def
winsup/w32api/lib/crypt32.def
winsup/w32api/lib/ctl3d32.def
winsup/w32api/lib/ddk/Makefile.in
winsup/w32api/lib/ddk/apcups.def
winsup/w32api/lib/ddk/cfgmgr32.def
winsup/w32api/lib/ddk/dxapi.def
winsup/w32api/lib/ddk/hal.def
winsup/w32api/lib/ddk/hid.def
winsup/w32api/lib/ddk/hidparse.def
winsup/w32api/lib/ddk/mcd.def
winsup/w32api/lib/ddk/ndis.def
winsup/w32api/lib/ddk/newdev.def
winsup/w32api/lib/ddk/ntoskrnl.def
winsup/w32api/lib/ddk/scsiport.def
winsup/w32api/lib/ddk/tdi.def
winsup/w32api/lib/ddk/usbcamd.def
winsup/w32api/lib/ddk/usbcamd2.def
winsup/w32api/lib/ddk/videoprt.def
winsup/w32api/lib/ddk/win32k.def
winsup/w32api/lib/devguid.c
winsup/w32api/lib/dhcpcsvc.def
winsup/w32api/lib/directx/Makefile.in
winsup/w32api/lib/directx/d3d8.def
winsup/w32api/lib/directx/d3d9.def
winsup/w32api/lib/directx/d3dim.def
winsup/w32api/lib/directx/d3drm.def
winsup/w32api/lib/directx/d3dx8d.def
winsup/w32api/lib/directx/d3dx9d.def
winsup/w32api/lib/directx/d3dxof.def
winsup/w32api/lib/directx/ddraw.def
winsup/w32api/lib/directx/dinput.def
winsup/w32api/lib/directx/dinput8.def
winsup/w32api/lib/directx/dinput_joy.c
winsup/w32api/lib/directx/dinput_joy2.c
winsup/w32api/lib/directx/dinput_kbd.c
winsup/w32api/lib/directx/dinput_mouse.c
winsup/w32api/lib/directx/dinput_mouse2.c
winsup/w32api/lib/directx/dinput_private.h
winsup/w32api/lib/directx/dmoguids.c
winsup/w32api/lib/directx/dplayx.def
winsup/w32api/lib/directx/dpnaddr.def
winsup/w32api/lib/directx/dpnet.def
winsup/w32api/lib/directx/dpnlobby.def
winsup/w32api/lib/directx/dpvoice.def
winsup/w32api/lib/directx/dsetup.def
winsup/w32api/lib/directx/dsound.def
winsup/w32api/lib/directx/dxerr.c
winsup/w32api/lib/directx/dxerr8.c
winsup/w32api/lib/directx/dxerr8w.c
winsup/w32api/lib/directx/dxerr9.c
winsup/w32api/lib/directx/dxerr9w.c
winsup/w32api/lib/directx/dxguid.c
winsup/w32api/lib/directx/ksproxy.def
winsup/w32api/lib/directx/ksuser.c
winsup/w32api/lib/directx/ksuser.def
winsup/w32api/lib/directx/msdmo.def
winsup/w32api/lib/directx/strmiids.c
winsup/w32api/lib/directx/test.c
winsup/w32api/lib/dlcapi.def
winsup/w32api/lib/dnsapi.def
winsup/w32api/lib/docobj-uuid.c
winsup/w32api/lib/exdisp-uuid.c
winsup/w32api/lib/extras-uuid.c
winsup/w32api/lib/faultrep.def
winsup/w32api/lib/gdi32.def
winsup/w32api/lib/glaux.def
winsup/w32api/lib/glu32.def
winsup/w32api/lib/hlguids-uuid.c
winsup/w32api/lib/hlink-uuid.c
winsup/w32api/lib/icmui.def
winsup/w32api/lib/igmpagnt.def
winsup/w32api/lib/imagehlp.def
winsup/w32api/lib/imm32.def
winsup/w32api/lib/iphlpapi.def
winsup/w32api/lib/kernel32.def
winsup/w32api/lib/largeint.c
winsup/w32api/lib/lz32.def
winsup/w32api/lib/mapi32.def
winsup/w32api/lib/mfcuia32.def
winsup/w32api/lib/mgmtapi.def
winsup/w32api/lib/mlang-uuid.c
winsup/w32api/lib/mpr.def
winsup/w32api/lib/mprapi.def
winsup/w32api/lib/mqrt.def
winsup/w32api/lib/msacm32.def
winsup/w32api/lib/mscms.def
winsup/w32api/lib/mshtml-uuid.c
winsup/w32api/lib/msimg32.def
winsup/w32api/lib/msvcp60.def
winsup/w32api/lib/msvfw32.def
winsup/w32api/lib/mswsock.def
winsup/w32api/lib/msxml-uuid.c
winsup/w32api/lib/nddeapi.def
winsup/w32api/lib/netapi32.def
winsup/w32api/lib/ntdll.def
winsup/w32api/lib/oaidl-uuid.c
winsup/w32api/lib/objidl-uuid.c
winsup/w32api/lib/objsafe-uuid.c
winsup/w32api/lib/ocidl-uuid.c
winsup/w32api/lib/odbc32.def
winsup/w32api/lib/odbccp32.def
winsup/w32api/lib/ole32.def
winsup/w32api/lib/oleacc-uuid.c
winsup/w32api/lib/oleacc.def
winsup/w32api/lib/oleaut32.def
winsup/w32api/lib/olecli32.def
winsup/w32api/lib/olectlid-uuid.c
winsup/w32api/lib/oledlg.def
winsup/w32api/lib/oleidl-uuid.c
winsup/w32api/lib/olepro32.def
winsup/w32api/lib/olesvr32.def
winsup/w32api/lib/opengl32.def
winsup/w32api/lib/penwin32.def
winsup/w32api/lib/pkpd32.def
winsup/w32api/lib/power-uuid.c
winsup/w32api/lib/powrprof.def
winsup/w32api/lib/psapi.def
winsup/w32api/lib/quartz.def
winsup/w32api/lib/rapi.def
winsup/w32api/lib/rasapi32.def
winsup/w32api/lib/rasdlg.def
winsup/w32api/lib/res.rc
winsup/w32api/lib/rpcdce4.def
winsup/w32api/lib/rpcns4.def
winsup/w32api/lib/rpcrt4.def
winsup/w32api/lib/rtm.def
winsup/w32api/lib/rtutils.def
winsup/w32api/lib/scrnsave.c
winsup/w32api/lib/secur32.def
winsup/w32api/lib/servprov-uuid.c
winsup/w32api/lib/setupapi.def
winsup/w32api/lib/shell32.c
winsup/w32api/lib/shell32.def
winsup/w32api/lib/shfolder.def
winsup/w32api/lib/shlwapi.def
winsup/w32api/lib/snmpapi.def
winsup/w32api/lib/svrapi.def
winsup/w32api/lib/tapi32.def
winsup/w32api/lib/test.c
winsup/w32api/lib/th32.def
winsup/w32api/lib/thunk32.def
winsup/w32api/lib/unknwn-uuid.c
winsup/w32api/lib/url.def
winsup/w32api/lib/urlmon-uuid.c
winsup/w32api/lib/user32.def
winsup/w32api/lib/userenv.def
winsup/w32api/lib/usp10.def
winsup/w32api/lib/uxtheme.def
winsup/w32api/lib/vdmdbg.def
winsup/w32api/lib/version.def
winsup/w32api/lib/vfw32.mri
winsup/w32api/lib/win32spl.def
winsup/w32api/lib/wininet.def
winsup/w32api/lib/winmm.def
winsup/w32api/lib/winspool.def
winsup/w32api/lib/winstrm.def
winsup/w32api/lib/wldap32.def
winsup/w32api/lib/wow32.def
winsup/w32api/lib/ws2_32.c
winsup/w32api/lib/ws2_32.def
winsup/w32api/lib/wsnmp32.def
winsup/w32api/lib/wsock32.def
winsup/w32api/lib/wst.def
winsup/w32api/lib/wtsapi32.def
Diffstat (limited to 'winsup/cygwin/fhandler_disk_file.cc')
-rw-r--r-- | winsup/cygwin/fhandler_disk_file.cc | 2250 |
1 files changed, 0 insertions, 2250 deletions
diff --git a/winsup/cygwin/fhandler_disk_file.cc b/winsup/cygwin/fhandler_disk_file.cc deleted file mode 100644 index 1ae9f9ea9..000000000 --- a/winsup/cygwin/fhandler_disk_file.cc +++ /dev/null @@ -1,2250 +0,0 @@ -/* fhandler_disk_file.cc - - Copyright 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, - 2005, 2006, 2007, 2008, 2009 Red Hat, Inc. - -This file is part of Cygwin. - -This software is a copyrighted work licensed under the terms of the -Cygwin license. Please consult the file "CYGWIN_LICENSE" for -details. */ - -#include "winsup.h" -#include <stdlib.h> -#include <sys/acl.h> -#include <sys/statvfs.h> -#include "cygerrno.h" -#include "security.h" -#include "path.h" -#include "fhandler.h" -#include "dtable.h" -#include "cygheap.h" -#include "shared_info.h" -#include "pinfo.h" -#include "ntdll.h" -#include "tls_pbuf.h" -#include "nfs.h" -#include "pwdgrp.h" -#include <winioctl.h> - -#define _COMPILING_NEWLIB -#include <dirent.h> - -class __DIR_mounts -{ - int count; - const char *parent_dir; - int parent_dir_len; - UNICODE_STRING mounts[MAX_MOUNTS]; - bool found[MAX_MOUNTS + 2]; - UNICODE_STRING cygdrive; - -#define __DIR_PROC (MAX_MOUNTS) -#define __DIR_CYGDRIVE (MAX_MOUNTS+1) - - __ino64_t eval_ino (int idx) - { - __ino64_t ino = 0; - char fname[parent_dir_len + mounts[idx].Length + 2]; - struct __stat64 st; - - char *c = stpcpy (fname, parent_dir); - if (c[- 1] != '/') - *c++ = '/'; - sys_wcstombs (c, mounts[idx].Length + 1, - mounts[idx].Buffer, mounts[idx].Length / sizeof (WCHAR)); - path_conv pc (fname, PC_SYM_NOFOLLOW | PC_POSIX); - if (!stat_worker (pc, &st)) - ino = st.st_ino; - return ino; - } - -public: - __DIR_mounts (const char *posix_path) - : parent_dir (posix_path) - { - parent_dir_len = strlen (parent_dir); - count = mount_table->get_mounts_here (parent_dir, parent_dir_len, mounts, - &cygdrive); - rewind (); - } - ~__DIR_mounts () - { - for (int i = 0; i < count; ++i) - RtlFreeUnicodeString (&mounts[i]); - RtlFreeUnicodeString (&cygdrive); - } - __ino64_t check_mount (PUNICODE_STRING fname, __ino64_t ino, - bool eval = true) - { - if (parent_dir_len == 1) /* root dir */ - { - if (RtlEqualUnicodeString (fname, &ro_u_proc, FALSE)) - { - found[__DIR_PROC] = true; - return 2; - } - if (fname->Length / sizeof (WCHAR) == mount_table->cygdrive_len - 2 - && RtlEqualUnicodeString (fname, &cygdrive, FALSE)) - { - found[__DIR_CYGDRIVE] = true; - return 2; - } - } - for (int i = 0; i < count; ++i) - if (RtlEqualUnicodeString (fname, &mounts[i], FALSE)) - { - found[i] = true; - return eval ? eval_ino (i) : 1; - } - return ino; - } - __ino64_t check_missing_mount (PUNICODE_STRING retname = NULL) - { - for (int i = 0; i < count; ++i) - if (!found[i]) - { - found[i] = true; - if (retname) - { - *retname = mounts[i]; - return eval_ino (i); - } - return 1; - } - if (parent_dir_len == 1) /* root dir */ - { - if (!found[__DIR_PROC]) - { - found[__DIR_PROC] = true; - if (retname) - RtlInitUnicodeString (retname, L"proc"); - return 2; - } - if (!found[__DIR_CYGDRIVE]) - { - found[__DIR_CYGDRIVE] = true; - if (cygdrive.Length > 0) - { - if (retname) - *retname = cygdrive; - return 2; - } - } - } - return 0; - } - void rewind () { memset (found, 0, sizeof found); } -}; - -inline bool -path_conv::isgood_inode (__ino64_t ino) const -{ - /* We can't trust remote inode numbers of only 32 bit. That means, - all remote inode numbers when running under NT4, as well as remote NT4 - NTFS, as well as shares of Samba version < 3.0. - The known exception are SFU NFS shares, which return the valid 32 bit - inode number from the remote file system unchanged. */ - return hasgood_inode () && (ino > UINT32_MAX || !isremote () || fs_is_nfs ()); -} - -static inline bool -is_volume_mountpoint (POBJECT_ATTRIBUTES attr) -{ - bool ret = false; - IO_STATUS_BLOCK io; - HANDLE reph; - UNICODE_STRING subst; - - if (NT_SUCCESS (NtOpenFile (&reph, READ_CONTROL, attr, &io, - FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT - | FILE_OPEN_REPARSE_POINT))) - { - PREPARSE_DATA_BUFFER rp = (PREPARSE_DATA_BUFFER) - alloca (MAXIMUM_REPARSE_DATA_BUFFER_SIZE); - if (NT_SUCCESS (NtFsControlFile (reph, NULL, NULL, NULL, - &io, FSCTL_GET_REPARSE_POINT, NULL, 0, - (LPVOID) rp, MAXIMUM_REPARSE_DATA_BUFFER_SIZE)) - && rp->ReparseTag == IO_REPARSE_TAG_MOUNT_POINT - && (RtlInitCountedUnicodeString (&subst, - (WCHAR *)((char *)rp->MountPointReparseBuffer.PathBuffer - + rp->MountPointReparseBuffer.SubstituteNameOffset), - rp->MountPointReparseBuffer.SubstituteNameLength), - RtlEqualUnicodePathPrefix (&subst, &ro_u_volume, TRUE))) - ret = true; - NtClose (reph); - } - return ret; -} - -static inline __ino64_t -get_ino_by_handle (path_conv &pc, HANDLE hdl) -{ - IO_STATUS_BLOCK io; - FILE_INTERNAL_INFORMATION fai; - - if (NT_SUCCESS (NtQueryInformationFile (hdl, &io, &fai, sizeof fai, - FileInternalInformation)) - && pc.isgood_inode (fai.FileId.QuadPart)) - return fai.FileId.QuadPart; - return 0; -} - -unsigned __stdcall -path_conv::ndisk_links (DWORD nNumberOfLinks) -{ - if (!isdir () || isremote ()) - return nNumberOfLinks; - - OBJECT_ATTRIBUTES attr; - IO_STATUS_BLOCK io; - HANDLE fh; - - if (!NT_SUCCESS (NtOpenFile (&fh, SYNCHRONIZE | FILE_LIST_DIRECTORY, - get_object_attr (attr, sec_none_nih), - &io, FILE_SHARE_VALID_FLAGS, - FILE_SYNCHRONOUS_IO_NONALERT - | FILE_OPEN_FOR_BACKUP_INTENT - | FILE_DIRECTORY_FILE))) - return nNumberOfLinks; - - unsigned count = 0; - bool first = true; - PFILE_DIRECTORY_INFORMATION fdibuf = (PFILE_DIRECTORY_INFORMATION) - alloca (65536); - __DIR_mounts *dir = new __DIR_mounts (normalized_path); - while (NT_SUCCESS (NtQueryDirectoryFile (fh, NULL, NULL, NULL, &io, fdibuf, - 65536, FileDirectoryInformation, - FALSE, NULL, first))) - { - if (first) - { - first = false; - /* All directories have . and .. as their first entries. - If . is not present as first entry, we're on a drive's - root direcotry, which doesn't have these entries. */ - if (fdibuf->FileNameLength != 2 || fdibuf->FileName[0] != L'.') - count = 2; - } - for (PFILE_DIRECTORY_INFORMATION pfdi = fdibuf; - pfdi; - pfdi = (PFILE_DIRECTORY_INFORMATION) - (pfdi->NextEntryOffset ? (PBYTE) pfdi + pfdi->NextEntryOffset - : NULL)) - { - switch (pfdi->FileAttributes - & (FILE_ATTRIBUTE_DIRECTORY | FILE_ATTRIBUTE_REPARSE_POINT)) - { - case FILE_ATTRIBUTE_DIRECTORY: - /* Just a directory */ - ++count; - break; - case FILE_ATTRIBUTE_DIRECTORY | FILE_ATTRIBUTE_REPARSE_POINT: - /* Volume mount point or symlink to directory */ - { - UNICODE_STRING fname; - - RtlInitCountedUnicodeString (&fname, pfdi->FileName, - pfdi->FileNameLength); - InitializeObjectAttributes (&attr, &fname, - objcaseinsensitive (), fh, NULL); - if (is_volume_mountpoint (&attr)) - ++count; - } - break; - default: - break; - } - UNICODE_STRING fname; - RtlInitCountedUnicodeString (&fname, pfdi->FileName, - pfdi->FileNameLength); - dir->check_mount (&fname, 0, false); - } - } - while (dir->check_missing_mount ()) - ++count; - NtClose (fh); - delete dir; - return count; -} - -/* For files on NFS shares, we request an EA of type NfsV3Attributes. - This returns the content of a struct fattr3 as defined in RFC 1813. - The content is the NFS equivalent of struct stat. so there's not much - to do here except for copying. */ -int __stdcall -fhandler_base::fstat_by_nfs_ea (struct __stat64 *buf) -{ - NTSTATUS status; - IO_STATUS_BLOCK io; - struct { - FILE_FULL_EA_INFORMATION ffei; - char buf[sizeof (NFS_V3_ATTR) + sizeof (fattr3)]; - } ffei_buf; - struct { - FILE_GET_EA_INFORMATION fgei; - char buf[sizeof (NFS_V3_ATTR)]; - } fgei_buf; - - fgei_buf.fgei.NextEntryOffset = 0; - fgei_buf.fgei.EaNameLength = sizeof (NFS_V3_ATTR) - 1; - stpcpy (fgei_buf.fgei.EaName, NFS_V3_ATTR); - status = NtQueryEaFile (get_handle (), &io, - &ffei_buf.ffei, sizeof ffei_buf, TRUE, - &fgei_buf.fgei, sizeof fgei_buf, NULL, TRUE); - if (NT_SUCCESS (status)) - { - fattr3 *nfs_attr = (fattr3 *) (ffei_buf.ffei.EaName - + ffei_buf.ffei.EaNameLength + 1); - buf->st_dev = nfs_attr->fsid; - buf->st_ino = nfs_attr->fileid; - buf->st_mode = (nfs_attr->mode & 0xfff) - | nfs_type_mapping[nfs_attr->type & 7]; - buf->st_nlink = nfs_attr->nlink; - /* FIXME: How to convert UNIX uid/gid to Windows SIDs? */ -#if 0 - buf->st_uid = nfs_attr->uid; - buf->st_gid = nfs_attr->gid; -#else - buf->st_uid = myself->uid; - buf->st_gid = myself->gid; -#endif - buf->st_rdev = makedev (nfs_attr->rdev.specdata1, - nfs_attr->rdev.specdata2); - buf->st_size = nfs_attr->size; - buf->st_blksize = PREFERRED_IO_BLKSIZE; - buf->st_blocks = nfs_attr->used / 512; - buf->st_atim = nfs_attr->atime; - buf->st_mtim = nfs_attr->mtime; - buf->st_ctim = nfs_attr->ctime; - return 0; - } - debug_printf ("%p = NtQueryEaFile(%S)", status, pc.get_nt_native_path ()); - return -1; -} - -int __stdcall -fhandler_base::fstat_by_handle (struct __stat64 *buf) -{ - NTSTATUS status; - IO_STATUS_BLOCK io; - - if (pc.fs_is_nfs ()) - return fstat_by_nfs_ea (buf); - - /* Don't use FileAllInformation info class. It returns a pathname rather - than a filename, so it needs a really big buffer for no good reason - since we don't need the name anyway. So we just call the three info - classes necessary to get all information required by stat(2). */ - FILE_BASIC_INFORMATION fbi; - FILE_STANDARD_INFORMATION fsi; - FILE_INTERNAL_INFORMATION fii; - - status = NtQueryInformationFile (get_handle (), &io, &fbi, sizeof fbi, - FileBasicInformation); - if (!NT_SUCCESS (status)) - { - debug_printf ("%p = NtQueryInformationFile(%S, FileBasicInformation)", - status, pc.get_nt_native_path ()); - return -1; - } - status = NtQueryInformationFile (get_handle (), &io, &fsi, sizeof fsi, - FileStandardInformation); - if (!NT_SUCCESS (status)) - { - debug_printf ("%p = NtQueryInformationFile(%S, FileStandardInformation)", - status, pc.get_nt_native_path ()); - return -1; - } - status = NtQueryInformationFile (get_handle (), &io, &fii, sizeof fii, - FileInternalInformation); - if (!NT_SUCCESS (status)) - { - debug_printf ("%p = NtQueryInformationFile(%S, FileInternalInformation)", - status, pc.get_nt_native_path ()); - return -1; - } - /* If the change time is 0, it's a file system which doesn't - support a change timestamp. In that case use the LastWriteTime - entry, as in other calls to fstat_helper. */ - if (pc.is_rep_symlink ()) - fbi.FileAttributes &= ~FILE_ATTRIBUTE_DIRECTORY; - pc.file_attributes (fbi.FileAttributes); - return fstat_helper (buf, - fbi.ChangeTime.QuadPart - ? *(FILETIME *) (void *) &fbi.ChangeTime - : *(FILETIME *) (void *) &fbi.LastWriteTime, - *(FILETIME *) (void *) &fbi.LastAccessTime, - *(FILETIME *) (void *) &fbi.LastWriteTime, - *(FILETIME *) (void *) &fbi.CreationTime, - get_dev (), - fsi.EndOfFile.QuadPart, - fsi.AllocationSize.QuadPart, - fii.FileId.QuadPart, - fsi.NumberOfLinks, - fbi.FileAttributes); -} - -int __stdcall -fhandler_base::fstat_by_name (struct __stat64 *buf) -{ - NTSTATUS status; - OBJECT_ATTRIBUTES attr; - IO_STATUS_BLOCK io; - UNICODE_STRING dirname; - UNICODE_STRING basename; - HANDLE dir; - struct { - FILE_ID_BOTH_DIR_INFORMATION fdi; - WCHAR buf[NAME_MAX + 1]; - } fdi_buf; - LARGE_INTEGER FileId; - - RtlSplitUnicodePath (pc.get_nt_native_path (), &dirname, &basename); - InitializeObjectAttributes (&attr, &dirname, pc.objcaseinsensitive (), - NULL, NULL); - if (!NT_SUCCESS (status = NtOpenFile (&dir, SYNCHRONIZE | FILE_LIST_DIRECTORY, - &attr, &io, FILE_SHARE_VALID_FLAGS, - FILE_SYNCHRONOUS_IO_NONALERT - | FILE_OPEN_FOR_BACKUP_INTENT - | FILE_DIRECTORY_FILE))) - { - debug_printf ("%p = NtOpenFile(%S)", status, pc.get_nt_native_path ()); - goto too_bad; - } - if (wincap.has_fileid_dirinfo () && !pc.has_buggy_fileid_dirinfo () - && NT_SUCCESS (status = NtQueryDirectoryFile (dir, NULL, NULL, NULL, &io, - &fdi_buf.fdi, sizeof fdi_buf, - FileIdBothDirectoryInformation, - TRUE, &basename, TRUE))) - FileId = fdi_buf.fdi.FileId; - else if (NT_SUCCESS (status = NtQueryDirectoryFile (dir, NULL, NULL, NULL, - &io, &fdi_buf.fdi, - sizeof fdi_buf, - FileDirectoryInformation, - TRUE, &basename, TRUE))) - FileId.QuadPart = 0; /* get_ino is called in fstat_helper. */ - if (!NT_SUCCESS (status)) - { - debug_printf ("%p = NtQueryDirectoryFile(%S)", status, - pc.get_nt_native_path ()); - NtClose (dir); - goto too_bad; - } - NtClose (dir); - /* If the change time is 0, it's a file system which doesn't - support a change timestamp. In that case use the LastWriteTime - entry, as in other calls to fstat_helper. */ - if (pc.is_rep_symlink ()) - fdi_buf.fdi.FileAttributes &= ~FILE_ATTRIBUTE_DIRECTORY; - pc.file_attributes (fdi_buf.fdi.FileAttributes); - return fstat_helper (buf, - fdi_buf.fdi.ChangeTime.QuadPart ? - *(FILETIME *) (void *) &fdi_buf.fdi.ChangeTime : - *(FILETIME *) (void *) &fdi_buf.fdi.LastWriteTime, - *(FILETIME *) (void *) &fdi_buf.fdi.LastAccessTime, - *(FILETIME *) (void *) &fdi_buf.fdi.LastWriteTime, - *(FILETIME *) (void *) &fdi_buf.fdi.CreationTime, - pc.fs_serial_number (), - fdi_buf.fdi.EndOfFile.QuadPart, - fdi_buf.fdi.AllocationSize.QuadPart, - FileId.QuadPart, - 1, - fdi_buf.fdi.FileAttributes); - -too_bad: - LARGE_INTEGER ft; - /* Arbitrary value: 2006-12-01 */ - RtlSecondsSince1970ToTime (1164931200L, &ft); - return fstat_helper (buf, - *(FILETIME *) (void *) &ft, - *(FILETIME *) (void *) &ft, - *(FILETIME *) (void *) &ft, - *(FILETIME *) (void *) &ft, - 0, - 0ULL, - -1LL, - 0ULL, - 1, - pc.file_attributes ()); -} - -int __stdcall -fhandler_base::fstat_fs (struct __stat64 *buf) -{ - int res = -1; - int oret; - int open_flags = O_RDONLY | O_BINARY; - - if (get_handle ()) - { - if (!nohandle () && !is_fs_special ()) - res = fstat_by_handle (buf); - if (res) - res = fstat_by_name (buf); - return res; - } - query_open (query_read_attributes); - oret = open_fs (open_flags, 0); - if (oret) - { - /* We now have a valid handle, regardless of the "nohandle" state. - Since fhandler_base::open only calls CloseHandle if !nohandle, - we have to set it to false before calling close and restore - the state afterwards. */ - res = fstat_by_handle (buf); - bool no_handle = nohandle (); - nohandle (false); - close_fs (); - nohandle (no_handle); - set_io_handle (NULL); - } - if (res) - res = fstat_by_name (buf); - - return res; -} - -/* The ftChangeTime is taken from the NTFS ChangeTime entry, if reading - the file information using NtQueryInformationFile succeeded. If not, - it's faked using the LastWriteTime entry from GetFileInformationByHandle - or FindFirstFile. We're deliberatly not using the creation time anymore - to simplify interaction with native Windows applications which choke on - creation times >= access or write times. - - Note that the dwFileAttributes member of the file information evaluated - in the calling function is used here, not the pc.fileattr member, since - the latter might be old and not reflect the actual state of the file. */ -int __stdcall -fhandler_base::fstat_helper (struct __stat64 *buf, - FILETIME ftChangeTime, - FILETIME ftLastAccessTime, - FILETIME ftLastWriteTime, - FILETIME ftCreationTime, - DWORD dwVolumeSerialNumber, - ULONGLONG nFileSize, - LONGLONG nAllocSize, - ULONGLONG nFileIndex, - DWORD nNumberOfLinks, - DWORD dwFileAttributes) -{ - IO_STATUS_BLOCK st; - FILE_COMPRESSION_INFORMATION fci; - - to_timestruc_t (&ftLastAccessTime, &buf->st_atim); - to_timestruc_t (&ftLastWriteTime, &buf->st_mtim); - to_timestruc_t (&ftChangeTime, &buf->st_ctim); - to_timestruc_t (&ftCreationTime, &buf->st_birthtim); - buf->st_dev = dwVolumeSerialNumber; - buf->st_size = (_off64_t) nFileSize; - /* The number of links to a directory includes the - number of subdirectories in the directory, since all - those subdirectories point to it. - This is too slow on remote drives, so we do without it. - Setting the count to 2 confuses `find (1)' command. So - let's try it with `1' as link count. */ -#if 0 - buf->st_nlink = pc.ndisk_links (nNumberOfLinks); -#else - buf->st_nlink = nNumberOfLinks; -#endif - - /* Enforce namehash as inode number on untrusted file systems. */ - if (pc.isgood_inode (nFileIndex)) - buf->st_ino = (__ino64_t) nFileIndex; - else - buf->st_ino = get_ino (); - - buf->st_blksize = PREFERRED_IO_BLKSIZE; - - if (nAllocSize >= 0LL) - /* A successful NtQueryInformationFile returns the allocation size - correctly for compressed and sparse files as well. */ - buf->st_blocks = (nAllocSize + S_BLKSIZE - 1) / S_BLKSIZE; - else if (::has_attribute (dwFileAttributes, FILE_ATTRIBUTE_COMPRESSED - | FILE_ATTRIBUTE_SPARSE_FILE) - && get_handle () && !is_fs_special () - && !NtQueryInformationFile (get_handle (), &st, (PVOID) &fci, - sizeof fci, FileCompressionInformation)) - /* Otherwise we request the actual amount of bytes allocated for - compressed and sparsed files. */ - buf->st_blocks = (fci.CompressedFileSize.QuadPart + S_BLKSIZE - 1) - / S_BLKSIZE; - else - /* Otherwise compute no. of blocks from file size. */ - buf->st_blocks = (buf->st_size + S_BLKSIZE - 1) / S_BLKSIZE; - - buf->st_mode = 0; - /* Using a side effect: get_file_attributes checks for directory. - This is used, to set S_ISVTX, if needed. */ - if (pc.isdir ()) - buf->st_mode = S_IFDIR; - else if (pc.issymlink ()) - { - buf->st_size = pc.get_symlink_length (); - /* symlinks are everything for everyone! */ - buf->st_mode = S_IFLNK | S_IRWXU | S_IRWXG | S_IRWXO; - get_file_attribute (get_handle (), pc, NULL, - &buf->st_uid, &buf->st_gid); - goto done; - } - else if (pc.issocket ()) - buf->st_mode = S_IFSOCK; - - if (!get_file_attribute (is_fs_special () && !pc.issocket () - ? NULL : get_handle (), pc, - &buf->st_mode, &buf->st_uid, &buf->st_gid)) - { - /* If read-only attribute is set, modify ntsec return value */ - if (::has_attribute (dwFileAttributes, FILE_ATTRIBUTE_READONLY) - && !pc.isdir () && !pc.issymlink ()) - buf->st_mode &= ~(S_IWUSR | S_IWGRP | S_IWOTH); - - if (buf->st_mode & S_IFMT) - /* nothing */; - else if (!is_fs_special ()) - buf->st_mode |= S_IFREG; - else - { - buf->st_dev = dev (); - buf->st_mode = dev ().mode; - buf->st_size = 0; - } - } - else - { - buf->st_mode |= STD_RBITS; - - if (!::has_attribute (dwFileAttributes, FILE_ATTRIBUTE_READONLY)) - buf->st_mode |= STD_WBITS; - /* | S_IWGRP | S_IWOTH; we don't give write to group etc */ - - if (pc.isdir ()) - buf->st_mode |= S_IFDIR | STD_WBITS | STD_XBITS; - else if (buf->st_mode & S_IFMT) - /* nothing */; - else if (is_fs_special ()) - { - buf->st_dev = dev (); - buf->st_mode = dev ().mode; - buf->st_size = 0; - } - else - { - buf->st_mode |= S_IFREG; - /* Check suffix for executable file. */ - if (pc.exec_state () == dont_know_if_executable) - { - PUNICODE_STRING path = pc.get_nt_native_path (); - - if (RtlEqualUnicodePathSuffix (path, &ro_u_exe, TRUE) - || RtlEqualUnicodePathSuffix (path, &ro_u_lnk, TRUE) - || RtlEqualUnicodePathSuffix (path, &ro_u_com, TRUE)) - pc.set_exec (); - } - /* No known suffix, check file header. This catches binaries and - shebang scripts. */ - if (pc.exec_state () == dont_know_if_executable) - { - OBJECT_ATTRIBUTES attr; - HANDLE h; - IO_STATUS_BLOCK io; - - InitializeObjectAttributes (&attr, &ro_u_empty, 0, get_handle (), - NULL); - if (NT_SUCCESS (NtOpenFile (&h, SYNCHRONIZE | FILE_READ_DATA, - &attr, &io, FILE_SHARE_VALID_FLAGS, - FILE_SYNCHRONOUS_IO_NONALERT))) - { - LARGE_INTEGER off = { QuadPart:0LL }; - char magic[3]; - - if (NT_SUCCESS (NtReadFile (h, NULL, NULL, NULL, &io, magic, - 3, &off, NULL)) - && has_exec_chars (magic, io.Information)) - { - pc.set_exec (); - buf->st_mode |= STD_XBITS; - } - NtClose (h); - } - } - } - if (pc.exec_state () == is_executable) - buf->st_mode |= STD_XBITS; - - /* This fakes the permissions of all files to match the current umask. */ - buf->st_mode &= ~(cygheap->umask); - /* If the FS supports ACLs, we're here because we couldn't even open - the file for READ_CONTROL access. Chances are high that the file's - security descriptor has no ACE for "Everyone", so we should not fake - any access for "others". */ - if (has_acls ()) - buf->st_mode &= ~(S_IROTH | S_IWOTH | S_IXOTH); - } - - done: - syscall_printf ("0 = fstat (, %p) st_atime=%x st_size=%D, st_mode=%p, st_ino=%D, sizeof=%d", - buf, buf->st_atime, buf->st_size, buf->st_mode, - buf->st_ino, sizeof (*buf)); - return 0; -} - -int __stdcall -fhandler_disk_file::fstat (struct __stat64 *buf) -{ - return fstat_fs (buf); -} - -int __stdcall -fhandler_disk_file::fstatvfs (struct statvfs *sfs) -{ - int ret = -1, opened = 0; - NTSTATUS status; - IO_STATUS_BLOCK io; - FILE_FS_FULL_SIZE_INFORMATION full_fsi; - FILE_FS_SIZE_INFORMATION fsi; - HANDLE fh = get_handle (); - - if (!fh) - { - OBJECT_ATTRIBUTES attr; - opened = NT_SUCCESS (NtOpenFile (&fh, READ_CONTROL, - pc.get_object_attr (attr, sec_none_nih), - &io, FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT)); - if (!opened) - { - /* Can't open file. Try again with parent dir. */ - UNICODE_STRING dirname; - RtlSplitUnicodePath (pc.get_nt_native_path (), &dirname, NULL); - attr.ObjectName = &dirname; - opened = NT_SUCCESS (NtOpenFile (&fh, READ_CONTROL, &attr, &io, - FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT)); - if (!opened) - goto out; - } - } - - sfs->f_files = ULONG_MAX; - sfs->f_ffree = ULONG_MAX; - sfs->f_favail = ULONG_MAX; - sfs->f_fsid = pc.fs_serial_number (); - sfs->f_flag = pc.fs_flags (); - sfs->f_namemax = pc.fs_name_len (); - /* Get allocation related information. Try to get "full" information - first, which is only available since W2K. If that fails, try to - retrieve normal allocation information. */ - status = NtQueryVolumeInformationFile (fh, &io, &full_fsi, sizeof full_fsi, - FileFsFullSizeInformation); - if (NT_SUCCESS (status)) - { - sfs->f_bsize = full_fsi.BytesPerSector * full_fsi.SectorsPerAllocationUnit; - sfs->f_frsize = sfs->f_bsize; - sfs->f_blocks = full_fsi.TotalAllocationUnits.LowPart; - sfs->f_bfree = full_fsi.ActualAvailableAllocationUnits.LowPart; - sfs->f_bavail = full_fsi.CallerAvailableAllocationUnits.LowPart; - if (sfs->f_bfree > sfs->f_bavail) - { - /* Quotas active. We can't trust TotalAllocationUnits. */ - NTFS_VOLUME_DATA_BUFFER nvdb; - - status = NtFsControlFile (fh, NULL, NULL, NULL, &io, - FSCTL_GET_NTFS_VOLUME_DATA, - NULL, 0, &nvdb, sizeof nvdb); - if (!NT_SUCCESS (status)) - debug_printf ("%p = NtFsControlFile(%S, FSCTL_GET_NTFS_VOLUME_DATA)", - status, pc.get_nt_native_path ()); - else - sfs->f_blocks = nvdb.TotalClusters.QuadPart; - } - ret = 0; - } - else - { - status = NtQueryVolumeInformationFile (fh, &io, &fsi, sizeof fsi, - FileFsSizeInformation); - if (!NT_SUCCESS (status)) - { - __seterrno_from_nt_status (status); - goto out; - } - sfs->f_bsize = fsi.BytesPerSector * fsi.SectorsPerAllocationUnit; - sfs->f_frsize = sfs->f_bsize; - sfs->f_blocks = fsi.TotalAllocationUnits.LowPart; - sfs->f_bfree = fsi.AvailableAllocationUnits.LowPart; - sfs->f_bavail = sfs->f_bfree; - ret = 0; - } -out: - if (opened) - NtClose (fh); - syscall_printf ("%d = fstatvfs (%s, %p)", ret, get_name (), sfs); - return ret; -} - -int __stdcall -fhandler_disk_file::fchmod (mode_t mode) -{ - extern int chmod_device (path_conv& pc, mode_t mode); - int res = -1; - int oret = 0; - NTSTATUS status; - IO_STATUS_BLOCK io; - - if (pc.is_fs_special ()) - return chmod_device (pc, mode); - - if (!get_handle ()) - { - query_open (query_write_control); - if (!(oret = open (O_BINARY, 0))) - { - /* Need WRITE_DAC|WRITE_OWNER to write ACLs. */ - if (pc.has_acls ()) - return -1; - /* Otherwise FILE_WRITE_ATTRIBUTES is sufficient. */ - query_open (query_write_attributes); - if (!(oret = open (O_BINARY, 0))) - return -1; - } - } - - if (pc.fs_is_nfs ()) - { - /* chmod on NFS shares works by writing an EA of type NfsV3Attributes. - Only type and mode have to be set. Apparently type isn't checked - for consistency, so it's sufficent to set it to NF3REG all the time. */ - struct { - FILE_FULL_EA_INFORMATION ffei; - char buf[sizeof (NFS_V3_ATTR) + sizeof (fattr3)]; - } ffei_buf; - ffei_buf.ffei.NextEntryOffset = 0; - ffei_buf.ffei.Flags = 0; - ffei_buf.ffei.EaNameLength = sizeof (NFS_V3_ATTR) - 1; - ffei_buf.ffei.EaValueLength = sizeof (fattr3); - strcpy (ffei_buf.ffei.EaName, NFS_V3_ATTR); - fattr3 *nfs_attr = (fattr3 *) (ffei_buf.ffei.EaName - + ffei_buf.ffei.EaNameLength + 1); - memset (nfs_attr, 0, sizeof (fattr3)); - nfs_attr->type = NF3REG; - nfs_attr->mode = mode; - status = NtSetEaFile (get_handle (), &io, - &ffei_buf.ffei, sizeof ffei_buf); - if (!NT_SUCCESS (status)) - __seterrno_from_nt_status (status); - else - res = 0; - goto out; - } - - if (pc.has_acls ()) - { - if (pc.isdir ()) - mode |= S_IFDIR; - if (!set_file_attribute (get_handle (), pc, - ILLEGAL_UID, ILLEGAL_GID, mode)) - res = 0; - } - - /* If the mode has any write bits set, the DOS R/O flag is in the way. */ - if (mode & (S_IWUSR | S_IWGRP | S_IWOTH)) - pc &= (DWORD) ~FILE_ATTRIBUTE_READONLY; - else if (!pc.has_acls ()) /* Never set DOS R/O if security is used. */ - pc |= (DWORD) FILE_ATTRIBUTE_READONLY; - if (S_ISSOCK (mode)) - pc |= (DWORD) FILE_ATTRIBUTE_SYSTEM; - - status = NtSetAttributesFile (get_handle (), pc.file_attributes ()); - /* MVFS needs a good amount of kicking to be convinced that it has to write - back metadata changes and to invalidate the cached metadata information - stored for the given handle. This method to open a second handle to - the file and write the same metadata information twice has been found - experimentally: http://cygwin.com/ml/cygwin/2009-07/msg00533.html */ - if (pc.fs_is_mvfs () && NT_SUCCESS (status) && !oret) - { - OBJECT_ATTRIBUTES attr; - HANDLE fh; - - InitializeObjectAttributes (&attr, &ro_u_empty, 0, get_handle (), NULL); - if (NT_SUCCESS (NtOpenFile (&fh, FILE_WRITE_ATTRIBUTES, &attr, &io, - FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT))) - { - NtSetAttributesFile (fh, pc.file_attributes ()); - NtClose (fh); - } - } - /* Correct NTFS security attributes have higher priority */ - if (!pc.has_acls ()) - { - if (!NT_SUCCESS (status)) - __seterrno_from_nt_status (status); - else - res = 0; - } - -out: - if (oret) - close_fs (); - - return res; -} - -int __stdcall -fhandler_disk_file::fchown (__uid32_t uid, __gid32_t gid) -{ - int oret = 0; - - if (!pc.has_acls ()) - { - /* fake - if not supported, pretend we're like win95 - where it just works */ - /* FIXME: Could be supported on NFS when user->uid mapping is in place. */ - return 0; - } - - if (!get_handle ()) - { - query_open (query_write_control); - if (!(oret = fhandler_disk_file::open (O_BINARY, 0))) - return -1; - } - - mode_t attrib = 0; - if (pc.isdir ()) - attrib |= S_IFDIR; - __uid32_t old_uid; - int res = get_file_attribute (get_handle (), pc, &attrib, &old_uid, NULL); - if (!res) - { - /* Typical Windows default ACLs can contain permissions for one - group, while being owned by another user/group. The permission - bits returned above are pretty much useless then. Creating a - new ACL with these useless permissions results in a potentially - broken symlink. So what we do here is to set the underlying - permissions of symlinks to a sensible value which allows the - world to read the symlink and only the new owner to change it. */ - if (pc.issymlink ()) - attrib = S_IFLNK | STD_RBITS | STD_WBITS; - res = set_file_attribute (get_handle (), pc, uid, gid, attrib); - /* If you're running a Samba server which has no winbidd running, the - uid<->SID mapping is disfunctional. Even trying to chown to your - own account fails since the account used on the server is the UNIX - account which gets used for the standard user mapping. This is a - default mechanism which doesn't know your real Windows SID. - There are two possible error codes in different Samba releases for - this situation, one of them is unfortunately the not very significant - STATUS_ACCESS_DENIED. Instead of relying on the error codes, we're - using the below very simple heuristic. If set_file_attribute failed, - and the original user account was either already unknown, or one of - the standard UNIX accounts, we're faking success. */ - if (res == -1 && pc.fs_is_samba ()) - { - cygsid sid; - - if (old_uid == ILLEGAL_UID - || (sid.getfrompw (internal_getpwuid (old_uid)) - && EqualPrefixSid (sid, well_known_samba_unix_user_fake_sid))) - { - debug_printf ("Faking chown worked on standalone Samba"); - res = 0; - } - } - } - if (oret) - close_fs (); - - return res; -} - -int _stdcall -fhandler_disk_file::facl (int cmd, int nentries, __aclent32_t *aclbufp) -{ - int res = -1; - int oret = 0; - - if (!pc.has_acls ()) - { -cant_access_acl: - switch (cmd) - { - struct __stat64 st; - - case SETACL: - /* Open for writing required to be able to set ctime - (even though setting the ACL is just pretended). */ - if (!get_handle ()) - oret = open (O_WRONLY | O_BINARY, 0); - res = 0; - break; - case GETACL: - if (!aclbufp) - set_errno (EFAULT); - else if (nentries < MIN_ACL_ENTRIES) - set_errno (ENOSPC); - else - { - if (!get_handle ()) - { - query_open (query_read_attributes); - oret = open (O_BINARY, 0); - } - if ((oret && !fstat_by_handle (&st)) - || !fstat_by_name (&st)) - { - aclbufp[0].a_type = USER_OBJ; - aclbufp[0].a_id = st.st_uid; - aclbufp[0].a_perm = (st.st_mode & S_IRWXU) >> 6; - aclbufp[1].a_type = GROUP_OBJ; - aclbufp[1].a_id = st.st_gid; - aclbufp[1].a_perm = (st.st_mode & S_IRWXG) >> 3; - aclbufp[2].a_type = OTHER_OBJ; - aclbufp[2].a_id = ILLEGAL_GID; - aclbufp[2].a_perm = st.st_mode & S_IRWXO; - aclbufp[3].a_type = CLASS_OBJ; - aclbufp[3].a_id = ILLEGAL_GID; - aclbufp[3].a_perm = S_IRWXU | S_IRWXG | S_IRWXO; - res = MIN_ACL_ENTRIES; - } - } - break; - case GETACLCNT: - res = MIN_ACL_ENTRIES; - break; - default: - set_errno (EINVAL); - break; - } - } - else - { - if (!get_handle ()) - { - query_open (cmd == SETACL ? query_write_control : query_read_control); - if (!(oret = open (O_BINARY, 0))) - { - if (cmd == GETACL || cmd == GETACLCNT) - goto cant_access_acl; - return -1; - } - } - switch (cmd) - { - case SETACL: - if (!aclsort32 (nentries, 0, aclbufp)) - { - bool rw = false; - res = setacl (get_handle (), pc, nentries, aclbufp, rw); - if (rw) - { - IO_STATUS_BLOCK io; - FILE_BASIC_INFORMATION fbi; - fbi.CreationTime.QuadPart - = fbi.LastAccessTime.QuadPart - = fbi.LastWriteTime.QuadPart - = fbi.ChangeTime.QuadPart = 0LL; - fbi.FileAttributes = (pc.file_attributes () - & ~FILE_ATTRIBUTE_READONLY) - ?: FILE_ATTRIBUTE_NORMAL; - NtSetInformationFile (get_handle (), &io, &fbi, sizeof fbi, - FileBasicInformation); - } - } - break; - case GETACL: - if (!aclbufp) - set_errno(EFAULT); - else - res = getacl (get_handle (), pc, nentries, aclbufp); - break; - case GETACLCNT: - res = getacl (get_handle (), pc, 0, NULL); - break; - default: - set_errno (EINVAL); - break; - } - } - - if (oret) - close_fs (); - - return res; -} - -ssize_t -fhandler_disk_file::fgetxattr (const char *name, void *value, size_t size) -{ - if (pc.is_fs_special ()) - { - set_errno (ENOTSUP); - return -1; - } - return read_ea (get_handle (), pc, name, (char *) value, size); -} - -int -fhandler_disk_file::fsetxattr (const char *name, const void *value, size_t size, - int flags) -{ - if (pc.is_fs_special ()) - { - set_errno (ENOTSUP); - return -1; - } - return write_ea (get_handle (), pc, name, (const char *) value, size, flags); -} - -int -fhandler_disk_file::fadvise (_off64_t offset, _off64_t length, int advice) -{ - if (advice < POSIX_FADV_NORMAL || advice > POSIX_FADV_NOREUSE) - { - set_errno (EINVAL); - return -1; - } - - /* Windows only supports advice flags for the whole file. We're using - a simplified test here so that we don't have to ask for the actual - file size. Length == 0 means all bytes starting at offset anyway. - So we only actually follow the advice, if it's given for offset == 0. */ - if (offset != 0) - return 0; - - /* We only support normal and sequential mode for now. Everything which - is not POSIX_FADV_SEQUENTIAL is treated like POSIX_FADV_NORMAL. */ - if (advice != POSIX_FADV_SEQUENTIAL) - advice = POSIX_FADV_NORMAL; - - IO_STATUS_BLOCK io; - FILE_MODE_INFORMATION fmi; - NTSTATUS status = NtQueryInformationFile (get_handle (), &io, - &fmi, sizeof fmi, - FileModeInformation); - if (!NT_SUCCESS (status)) - __seterrno_from_nt_status (status); - else - { - fmi.Mode &= ~FILE_SEQUENTIAL_ONLY; - if (advice == POSIX_FADV_SEQUENTIAL) - fmi.Mode |= FILE_SEQUENTIAL_ONLY; - status = NtSetInformationFile (get_handle (), &io, &fmi, sizeof fmi, - FileModeInformation); - if (NT_SUCCESS (status)) - return 0; - __seterrno_from_nt_status (status); - } - - return -1; -} - -int -fhandler_disk_file::ftruncate (_off64_t length, bool allow_truncate) -{ - int res = -1; - - if (length < 0 || !get_handle ()) - set_errno (EINVAL); - else if (pc.isdir ()) - set_errno (EISDIR); - else if (!(get_access () & GENERIC_WRITE)) - set_errno (EBADF); - else - { - NTSTATUS status; - IO_STATUS_BLOCK io; - FILE_STANDARD_INFORMATION fsi; - FILE_END_OF_FILE_INFORMATION feofi; - - status = NtQueryInformationFile (get_handle (), &io, &fsi, sizeof fsi, - FileStandardInformation); - if (!NT_SUCCESS (status)) - { - __seterrno_from_nt_status (status); - return -1; - } - - /* If called through posix_fallocate, silently succeed if length - is less than the file's actual length. */ - if (!allow_truncate && length < fsi.EndOfFile.QuadPart) - return 0; - - feofi.EndOfFile.QuadPart = length; - /* Create sparse files only when called through ftruncate, not when - called through posix_fallocate. */ - if (allow_truncate - && (pc.fs_flags () & FILE_SUPPORTS_SPARSE_FILES) - && length >= fsi.EndOfFile.QuadPart + (128 * 1024)) - { - status = NtFsControlFile (get_handle (), NULL, NULL, NULL, &io, - FSCTL_SET_SPARSE, NULL, 0, NULL, 0); - syscall_printf ("%p = NtFsControlFile(%S, FSCTL_SET_SPARSE)", - status, pc.get_nt_native_path ()); - } - status = NtSetInformationFile (get_handle (), &io, - &feofi, sizeof feofi, - FileEndOfFileInformation); - if (!NT_SUCCESS (status)) - __seterrno_from_nt_status (status); - else - res = 0; - } - return res; -} - -int -fhandler_disk_file::link (const char *newpath) -{ - size_t nlen = strlen (newpath); - path_conv newpc (newpath, PC_SYM_NOFOLLOW | PC_POSIX | PC_NULLEMPTY, stat_suffixes); - if (newpc.error) - { - set_errno (newpc.error); - return -1; - } - - if (newpc.exists ()) - { - syscall_printf ("file '%S' exists?", newpc.get_nt_native_path ()); - set_errno (EEXIST); - return -1; - } - - if (isdirsep (newpath[nlen - 1]) || has_dot_last_component (newpath, false)) - { - set_errno (ENOENT); - return -1; - } - - char new_buf[nlen + 5]; - if (!newpc.error) - { - /* If the original file is a lnk special file (except for sockets), - and if the original file has a .lnk suffix, add one to the hardlink - as well. */ - if (pc.is_lnk_special () && !pc.issocket () - && RtlEqualUnicodePathSuffix (pc.get_nt_native_path (), - &ro_u_lnk, TRUE)) - { - /* Shortcut hack. */ - stpcpy (stpcpy (new_buf, newpath), ".lnk"); - newpath = new_buf; - newpc.check (newpath, PC_SYM_NOFOLLOW); - } - else if (!pc.isdir () - && pc.is_binary () - && RtlEqualUnicodePathSuffix (pc.get_nt_native_path (), - &ro_u_exe, TRUE) - && !RtlEqualUnicodePathSuffix (newpc.get_nt_native_path (), - &ro_u_exe, TRUE)) - { - /* Executable hack. */ - stpcpy (stpcpy (new_buf, newpath), ".exe"); - newpath = new_buf; - newpc.check (newpath, PC_SYM_NOFOLLOW); - } - } - - HANDLE fh; - NTSTATUS status; - OBJECT_ATTRIBUTES attr; - IO_STATUS_BLOCK io; - status = NtOpenFile (&fh, READ_CONTROL, - pc.get_object_attr (attr, sec_none_nih), &io, - FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT | FILE_OPEN_REPARSE_POINT); - if (!NT_SUCCESS (status)) - { - __seterrno_from_nt_status (status); - return -1; - } - PUNICODE_STRING tgt = newpc.get_nt_native_path (); - ULONG size = sizeof (FILE_LINK_INFORMATION) + tgt->Length; - PFILE_LINK_INFORMATION pfli = (PFILE_LINK_INFORMATION) alloca (size); - pfli->ReplaceIfExists = FALSE; - pfli->RootDirectory = NULL; - memcpy (pfli->FileName, tgt->Buffer, pfli->FileNameLength = tgt->Length); - status = NtSetInformationFile (fh, &io, pfli, size, FileLinkInformation); - NtClose (fh); - if (!NT_SUCCESS (status)) - { - if (status == STATUS_INVALID_DEVICE_REQUEST) - { - /* FS doesn't support hard links. Linux returns EPERM. */ - set_errno (EPERM); - return -1; - } - else - { - __seterrno_from_nt_status (status); - return -1; - } - } - return 0; -} - -int -fhandler_disk_file::utimens (const struct timespec *tvp) -{ - return utimens_fs (tvp); -} - -int -fhandler_base::utimens_fs (const struct timespec *tvp) -{ - struct timespec timeofday; - struct timespec tmp[2]; - bool closeit = false; - - if (!get_handle ()) - { - query_open (query_write_attributes); - if (!open_fs (O_BINARY, 0)) - { - /* It's documented in MSDN that FILE_WRITE_ATTRIBUTES is sufficient - to change the timestamps. Unfortunately it's not sufficient for a - remote HPFS which requires GENERIC_WRITE, so we just retry to open - for writing, though this fails for R/O files of course. */ - query_open (no_query); - if (!open_fs (O_WRONLY | O_BINARY, 0)) - { - syscall_printf ("Opening file failed"); - return -1; - } - } - closeit = true; - } - - clock_gettime (CLOCK_REALTIME, &timeofday); - if (!tvp) - tmp[1] = tmp[0] = timeofday; - else - { - if ((tvp[0].tv_nsec < UTIME_NOW || tvp[0].tv_nsec > 999999999L) - || (tvp[1].tv_nsec < UTIME_NOW || tvp[1].tv_nsec > 999999999L)) - { - if (closeit) - close_fs (); - set_errno (EINVAL); - return -1; - } - tmp[0] = (tvp[0].tv_nsec == UTIME_NOW) ? timeofday : tvp[0]; - tmp[1] = (tvp[1].tv_nsec == UTIME_NOW) ? timeofday : tvp[1]; - } - debug_printf ("incoming lastaccess %08x %08x", tmp[0].tv_sec, tmp[0].tv_nsec); - - IO_STATUS_BLOCK io; - FILE_BASIC_INFORMATION fbi; - - fbi.CreationTime.QuadPart = 0LL; - /* UTIME_OMIT is handled in timespec_to_filetime by setting FILETIME to 0. */ - timespec_to_filetime (&tmp[0], (LPFILETIME) &fbi.LastAccessTime); - timespec_to_filetime (&tmp[1], (LPFILETIME) &fbi.LastWriteTime); - fbi.ChangeTime.QuadPart = 0LL; - fbi.FileAttributes = 0; - NTSTATUS status = NtSetInformationFile (get_handle (), &io, &fbi, sizeof fbi, - FileBasicInformation); - /* For this special case for MVFS see the comment in - fhandler_disk_file::fchmod. */ - if (pc.fs_is_mvfs () && NT_SUCCESS (status) && !closeit) - { - OBJECT_ATTRIBUTES attr; - HANDLE fh; - - InitializeObjectAttributes (&attr, &ro_u_empty, 0, get_handle (), NULL); - if (NT_SUCCESS (NtOpenFile (&fh, FILE_WRITE_ATTRIBUTES, &attr, &io, - FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT))) - { - NtSetInformationFile (fh, &io, &fbi, sizeof fbi, - FileBasicInformation); - NtClose (fh); - } - } - if (closeit) - close_fs (); - /* Opening a directory on a 9x share from a NT machine works(!), but - then NtSetInformationFile fails with STATUS_NOT_SUPPORTED. Oh well... */ - if (!NT_SUCCESS (status) && status != STATUS_NOT_SUPPORTED) - { - __seterrno_from_nt_status (status); - return -1; - } - return 0; -} - -fhandler_disk_file::fhandler_disk_file () : - fhandler_base () -{ -} - -fhandler_disk_file::fhandler_disk_file (path_conv &pc) : - fhandler_base () -{ - set_name (pc); -} - -int -fhandler_disk_file::open (int flags, mode_t mode) -{ - return open_fs (flags, mode); -} - -int -fhandler_base::open_fs (int flags, mode_t mode) -{ - /* Unfortunately NT allows to open directories for writing, but that's - disallowed according to SUSv3. */ - if (pc.isdir () && (flags & O_ACCMODE) != O_RDONLY) - { - set_errno (EISDIR); - return 0; - } - - int res = fhandler_base::open (flags | O_DIROPEN, mode); - if (!res) - goto out; - - /* This is for file systems known for having a buggy CreateFile call - which might return a valid HANDLE without having actually opened - the file. - The only known file system to date is the SUN NFS Solstice Client 3.1 - which returns a valid handle when trying to open a file in a nonexistent - directory. */ - if (pc.has_buggy_open () && !pc.exists ()) - { - debug_printf ("Buggy open detected."); - close_fs (); - set_errno (ENOENT); - return 0; - } - - ino = get_ino_by_handle (pc, get_handle ()); - /* A unique ID is necessary to recognize fhandler entries which are - duplicated by dup(2) or fork(2). */ - AllocateLocallyUniqueId ((PLUID) &unique_id); - -out: - syscall_printf ("%d = fhandler_disk_file::open (%S, %p)", res, - pc.get_nt_native_path (), flags); - return res; -} - -ssize_t __stdcall -fhandler_disk_file::pread (void *buf, size_t count, _off64_t offset) -{ - ssize_t res; - _off64_t curpos = lseek (0, SEEK_CUR); - if (curpos < 0 || lseek (offset, SEEK_SET) < 0) - res = -1; - else - { - size_t tmp_count = count; - read (buf, tmp_count); - if (lseek (curpos, SEEK_SET) >= 0) - res = (ssize_t) tmp_count; - else - res = -1; - } - debug_printf ("%d = pread (%p, %d, %d)\n", res, buf, count, offset); - return res; -} - -ssize_t __stdcall -fhandler_disk_file::pwrite (void *buf, size_t count, _off64_t offset) -{ - int res; - _off64_t curpos = lseek (0, SEEK_CUR); - if (curpos < 0 || lseek (offset, SEEK_SET) < 0) - res = curpos; - else - { - res = (ssize_t) write (buf, count); - if (lseek (curpos, SEEK_SET) < 0) - res = -1; - } - debug_printf ("%d = pwrite (%p, %d, %d)\n", res, buf, count, offset); - return res; -} - -int -fhandler_disk_file::mkdir (mode_t mode) -{ - int res = -1; - SECURITY_ATTRIBUTES sa = sec_none_nih; - NTSTATUS status; - HANDLE dir; - OBJECT_ATTRIBUTES attr; - IO_STATUS_BLOCK io; - PFILE_FULL_EA_INFORMATION p = NULL; - ULONG plen = 0; - - if (pc.fs_is_nfs ()) - { - /* When creating a dir on an NFS share, we have to set the - file mode by writing a NFS fattr3 structure with the - correct mode bits set. */ - plen = sizeof (FILE_FULL_EA_INFORMATION) + sizeof (NFS_V3_ATTR) - + sizeof (fattr3); - p = (PFILE_FULL_EA_INFORMATION) alloca (plen); - p->NextEntryOffset = 0; - p->Flags = 0; - p->EaNameLength = sizeof (NFS_V3_ATTR) - 1; - p->EaValueLength = sizeof (fattr3); - strcpy (p->EaName, NFS_V3_ATTR); - fattr3 *nfs_attr = (fattr3 *) (p->EaName + p->EaNameLength + 1); - memset (nfs_attr, 0, sizeof (fattr3)); - nfs_attr->type = NF3DIR; - nfs_attr->mode = (mode & 07777) & ~cygheap->umask; - } - status = NtCreateFile (&dir, FILE_LIST_DIRECTORY | SYNCHRONIZE, - pc.get_object_attr (attr, sa), &io, NULL, - FILE_ATTRIBUTE_DIRECTORY, FILE_SHARE_VALID_FLAGS, - FILE_CREATE, - FILE_DIRECTORY_FILE | FILE_SYNCHRONOUS_IO_NONALERT - | FILE_OPEN_FOR_BACKUP_INTENT, - p, plen); - if (NT_SUCCESS (status)) - { - if (has_acls ()) - set_file_attribute (dir, pc, ILLEGAL_UID, ILLEGAL_GID, - S_JUSTCREATED | S_IFDIR - | ((mode & 07777) & ~cygheap->umask)); - NtClose (dir); - res = 0; - } - else - __seterrno_from_nt_status (status); - - return res; -} - -int -fhandler_disk_file::rmdir () -{ - extern NTSTATUS unlink_nt (path_conv &pc); - - if (!pc.isdir ()) - { - set_errno (ENOTDIR); - return -1; - } - if (!pc.exists ()) - { - set_errno (ENOENT); - return -1; - } - - NTSTATUS status = unlink_nt (pc); - - /* Check for existence of remote dirs after trying to delete them. - Two reasons: - - Sometimes SMB indicates failure when it really succeeds. - - Removeing a directory on a samba drive doesn't return an error if the - directory can't be removed because it's not empty. */ - if (isremote ()) - { - OBJECT_ATTRIBUTES attr; - FILE_BASIC_INFORMATION fbi; - - if (NT_SUCCESS (NtQueryAttributesFile - (pc.get_object_attr (attr, sec_none_nih), &fbi))) - status = STATUS_DIRECTORY_NOT_EMPTY; - else - status = STATUS_SUCCESS; - } - if (!NT_SUCCESS (status)) - { - __seterrno_from_nt_status (status); - return -1; - } - return 0; -} - -/* This is the minimal number of entries which fit into the readdir cache. - The number of bytes allocated by the cache is determined by this number, - To tune caching, just tweak this number. To get a feeling for the size, - the size of the readdir cache is DIR_NUM_ENTRIES * 624 + 4 bytes. */ - -#define DIR_NUM_ENTRIES 100 /* Cache size 62404 bytes */ - -#define DIR_BUF_SIZE (DIR_NUM_ENTRIES \ - * (sizeof (FILE_ID_BOTH_DIR_INFORMATION) \ - + (NAME_MAX + 1) * sizeof (WCHAR))) - -struct __DIR_cache -{ - char __cache[DIR_BUF_SIZE]; /* W2K needs this buffer 8 byte aligned. */ - ULONG __pos; -}; - -#define d_cachepos(d) (((__DIR_cache *) (d)->__d_dirname)->__pos) -#define d_cache(d) (((__DIR_cache *) (d)->__d_dirname)->__cache) - -#define d_mounts(d) ((__DIR_mounts *) (d)->__d_internal) - -DIR * -fhandler_disk_file::opendir (int fd) -{ - DIR *dir; - DIR *res = NULL; - - if (!pc.isdir ()) - set_errno (ENOTDIR); - else if ((dir = (DIR *) malloc (sizeof (DIR))) == NULL) - set_errno (ENOMEM); - else if ((dir->__d_dirname = (char *) malloc ( sizeof (struct __DIR_cache))) - == NULL) - { - set_errno (ENOMEM); - goto free_dir; - } - else if ((dir->__d_dirent = - (struct dirent *) malloc (sizeof (struct dirent))) == NULL) - { - set_errno (ENOMEM); - goto free_dirname; - } - else - { - cygheap_fdnew cfd; - if (cfd < 0 && fd < 0) - goto free_dirent; - - dir->__d_dirent->__d_version = __DIRENT_VERSION; - dir->__d_cookie = __DIRENT_COOKIE; - dir->__handle = INVALID_HANDLE_VALUE; - dir->__d_position = 0; - dir->__flags = (get_name ()[0] == '/' && get_name ()[1] == '\0') - ? dirent_isroot : 0; - dir->__d_internal = (unsigned) new __DIR_mounts (get_name ()); - d_cachepos (dir) = 0; - - if (!pc.iscygdrive ()) - { - if (fd < 0) - { - /* opendir() case. Initialize with given directory name and - NULL directory handle. */ - OBJECT_ATTRIBUTES attr; - NTSTATUS status; - IO_STATUS_BLOCK io; - - status = NtOpenFile (&get_handle (), - SYNCHRONIZE | FILE_LIST_DIRECTORY, - pc.get_object_attr (attr, sec_none_nih), - &io, FILE_SHARE_VALID_FLAGS, - FILE_SYNCHRONOUS_IO_NONALERT - | FILE_OPEN_FOR_BACKUP_INTENT - | FILE_DIRECTORY_FILE); - if (!NT_SUCCESS (status)) - { - __seterrno_from_nt_status (status); - goto free_mounts; - } - } - - /* FileIdBothDirectoryInformation is apparently unsupported on - XP when accessing directories on UDF. When trying to use it - so, NtQueryDirectoryFile returns with STATUS_ACCESS_VIOLATION. - It's not clear if the call isn't also unsupported on other - OS/FS combinations (say, Win2K/CDFS or so). Instead of - testing in readdir for yet another error code, let's use - FileIdBothDirectoryInformation only on filesystems supporting - persistent ACLs, FileDirectoryInformation otherwise. - - NFS clients hide dangling symlinks from directory queries, - unless you use the FileNamesInformation info class. - On newer NFS clients (>=Vista) FileIdBothDirectoryInformation - works fine, but only if the NFS share is mounted to a drive - letter. TODO: We don't test that here for now, but it might - be worth to test if there's a speed gain in using - FileIdBothDirectoryInformation, because it doesn't require to - open the file to read the inode number. */ - if (pc.hasgood_inode ()) - { - dir->__flags |= dirent_set_d_ino; - if (pc.fs_is_nfs ()) - dir->__flags |= dirent_nfs_d_ino; - else if (wincap.has_fileid_dirinfo () - && !pc.has_buggy_fileid_dirinfo ()) - dir->__flags |= dirent_get_d_ino; - } - } - if (fd >= 0) - dir->__d_fd = fd; - else - { - /* Filling cfd with `this' (aka storing this in the file - descriptor table should only happen after it's clear that - opendir doesn't fail, otherwise we end up cfree'ing the - fhandler twice, once in opendir() in dir.cc, the second - time on exit. Nasty, nasty... */ - cfd = this; - dir->__d_fd = cfd; - if (pc.iscygdrive ()) - cfd->nohandle (true); - } - set_close_on_exec (true); - dir->__fh = this; - res = dir; - } - - syscall_printf ("%p = opendir (%s)", res, get_name ()); - return res; - -free_mounts: - delete d_mounts (dir); -free_dirent: - free (dir->__d_dirent); -free_dirname: - free (dir->__d_dirname); -free_dir: - free (dir); - return res; -} - -__ino64_t __stdcall -readdir_get_ino (const char *path, bool dot_dot) -{ - char *fname; - struct __stat64 st; - HANDLE hdl; - OBJECT_ATTRIBUTES attr; - IO_STATUS_BLOCK io; - __ino64_t ino = 0; - - if (dot_dot) - { - fname = (char *) alloca (strlen (path) + 4); - char *c = stpcpy (fname, path); - if (c[-1] != '/') - *c++ = '/'; - strcpy (c, ".."); - path = fname; - } - path_conv pc (path, PC_SYM_NOFOLLOW | PC_POSIX | PC_NOWARN); - if (pc.isspecial ()) - { - if (!stat_worker (pc, &st)) - ino = st.st_ino; - } - else if (!pc.hasgood_inode ()) - ino = hash_path_name (0, pc.get_nt_native_path ()); - else if (NT_SUCCESS (NtOpenFile (&hdl, READ_CONTROL, - pc.get_object_attr (attr, sec_none_nih), - &io, FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT - | (pc.is_rep_symlink () - ? FILE_OPEN_REPARSE_POINT : 0)))) - { - ino = get_ino_by_handle (pc, hdl); - if (!ino) - ino = hash_path_name (0, pc.get_nt_native_path ()); - NtClose (hdl); - } - return ino; -} - -int -fhandler_disk_file::readdir_helper (DIR *dir, dirent *de, DWORD w32_err, - DWORD attr, PUNICODE_STRING fname) -{ - if (w32_err) - { - bool added = false; - if ((de->d_ino = d_mounts (dir)->check_missing_mount (fname))) - added = true; - if (!added) - return geterrno_from_win_error (w32_err); - - attr = 0; - dir->__flags &= ~dirent_set_d_ino; - } - - /* Set d_type if type can be determined from file attributes. - FILE_ATTRIBUTE_SYSTEM ommitted to leave DT_UNKNOWN for old symlinks. - For new symlinks, d_type will be reset to DT_UNKNOWN below. */ - if (attr && - !(attr & ( ~FILE_ATTRIBUTE_VALID_FLAGS - | FILE_ATTRIBUTE_SYSTEM - | FILE_ATTRIBUTE_REPARSE_POINT))) - { - if (attr & FILE_ATTRIBUTE_DIRECTORY) - de->d_type = DT_DIR; - else - de->d_type = DT_REG; - } - - /* Check for directory reparse point. These are potential volume mount - points which have another inode than the underlying directory. */ - if ((attr & (FILE_ATTRIBUTE_DIRECTORY | FILE_ATTRIBUTE_REPARSE_POINT)) - == (FILE_ATTRIBUTE_DIRECTORY | FILE_ATTRIBUTE_REPARSE_POINT)) - { - HANDLE reph; - OBJECT_ATTRIBUTES attr; - IO_STATUS_BLOCK io; - - InitializeObjectAttributes (&attr, fname, pc.objcaseinsensitive (), - get_handle (), NULL); - if (is_volume_mountpoint (&attr) - && (NT_SUCCESS (NtOpenFile (&reph, READ_CONTROL, &attr, &io, - FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT)))) - { - de->d_ino = get_ino_by_handle (pc, reph); - NtClose (reph); - } - } - - /* Check for Windows shortcut. If it's a Cygwin or U/WIN - symlink, drop the .lnk suffix. */ - if ((attr & FILE_ATTRIBUTE_READONLY) && fname->Length > 4 * sizeof (WCHAR)) - { - UNICODE_STRING uname; - - RtlInitCountedUnicodeString (&uname, - fname->Buffer - + fname->Length / sizeof (WCHAR) - 4, - 4 * sizeof (WCHAR)); - if (RtlEqualUnicodeString (&uname, &ro_u_lnk, TRUE)) - { - tmp_pathbuf tp; - UNICODE_STRING fbuf; - - tp.u_get (&fbuf); - RtlCopyUnicodeString (&fbuf, pc.get_nt_native_path ()); - RtlAppendUnicodeToString (&fbuf, L"\\"); - RtlAppendUnicodeStringToString (&fbuf, fname); - fbuf.Buffer += 4; /* Skip leading \??\ */ - fbuf.Length -= 4 * sizeof (WCHAR); - if (fbuf.Buffer[1] != L':') /* UNC path */ - { - *(fbuf.Buffer += 2) = L'\\'; - fbuf.Length -= 2 * sizeof (WCHAR); - } - path_conv fpath (&fbuf, PC_SYM_NOFOLLOW); - if (fpath.issymlink () || fpath.is_fs_special ()) - { - fname->Length -= 4 * sizeof (WCHAR); - de->d_type = DT_UNKNOWN; - } - } - } - - sys_wcstombs (de->d_name, NAME_MAX + 1, fname->Buffer, - fname->Length / sizeof (WCHAR)); - - /* Don't try to optimize relative to dir->__d_position. On several - filesystems it's no safe bet that "." and ".." entries always - come first. */ - if (de->d_name[0] == '.') - { - if (de->d_name[1] == '\0') - dir->__flags |= dirent_saw_dot; - else if (de->d_name[1] == '.' && de->d_name[2] == '\0') - dir->__flags |= dirent_saw_dot_dot; - } - return 0; -} - -int -fhandler_disk_file::readdir (DIR *dir, dirent *de) -{ - int res = 0; - NTSTATUS status = STATUS_SUCCESS; - PFILE_ID_BOTH_DIR_INFORMATION buf = NULL; - PWCHAR FileName; - ULONG FileNameLength; - ULONG FileAttributes = 0; - IO_STATUS_BLOCK io; - UNICODE_STRING fname; - - /* d_cachepos always refers to the next cache entry to use. If it's 0 - we must reload the cache. */ - if (d_cachepos (dir) == 0) - { - if ((dir->__flags & dirent_get_d_ino)) - { - status = NtQueryDirectoryFile (get_handle (), NULL, NULL, NULL, &io, - d_cache (dir), DIR_BUF_SIZE, - FileIdBothDirectoryInformation, - FALSE, NULL, dir->__d_position == 0); - /* FileIdBothDirectoryInformation isn't supported for remote drives - on NT4 and 2K systems, and it's also not supported on 2K at all, - when accessing network drives on any remote OS. There are also - hacked versions of Samba 3.0.x out there (Debian-based it seems), - which return STATUS_NOT_SUPPORTED rather than handling this info - class. We just fall back to using a standard directory query in - this case and note this case using the dirent_get_d_ino flag. */ - if (status == STATUS_INVALID_LEVEL - || status == STATUS_NOT_SUPPORTED - || status == STATUS_INVALID_PARAMETER - || status == STATUS_INVALID_INFO_CLASS) - dir->__flags &= ~dirent_get_d_ino; - /* Something weird happens on Samba up to version 3.0.21c, which is - fixed in 3.0.22. FileIdBothDirectoryInformation seems to work - nicely, but only up to the 128th entry in the directory. After - reaching this entry, the next call to NtQueryDirectoryFile - (FileIdBothDirectoryInformation) returns STATUS_INVALID_LEVEL. - Why should we care, we can just switch to FileDirectoryInformation, - isn't it? Nope! The next call to - NtQueryDirectoryFile(FileDirectoryInformation) - actually returns STATUS_NO_MORE_FILES, regardless how many files - are left unread in the directory. This does not happen when using - FileDirectoryInformation right from the start, but since - we can't decide whether the server we're talking with has this - bug or not, we end up serving Samba shares always in the slow - mode using FileDirectoryInformation. So, what we do here is - to implement the solution suggested by Andrew Tridgell, we just - reread all entries up to dir->d_position using - FileDirectoryInformation. - However, We do *not* mark this server as broken and fall back to - using FileDirectoryInformation further on. This would slow - down every access to such a server, even for directories under - 128 entries. Also, bigger dirs only suffer from one additional - call per full directory scan, which shouldn't be too big a hit. - This can easily be changed if necessary. */ - if (status == STATUS_INVALID_LEVEL && dir->__d_position) - { - d_cachepos (dir) = 0; - for (int cnt = 0; cnt < dir->__d_position; ++cnt) - { - if (d_cachepos (dir) == 0) - { - status = NtQueryDirectoryFile (get_handle (), NULL, NULL, - NULL, &io, d_cache (dir), - DIR_BUF_SIZE, - FileDirectoryInformation, - FALSE, NULL, cnt == 0); - if (!NT_SUCCESS (status)) - goto go_ahead; - } - buf = (PFILE_ID_BOTH_DIR_INFORMATION) (d_cache (dir) - + d_cachepos (dir)); - if (buf->NextEntryOffset == 0) - d_cachepos (dir) = 0; - else - d_cachepos (dir) += buf->NextEntryOffset; - } - goto go_ahead; - } - } - if (!(dir->__flags & dirent_get_d_ino)) - status = NtQueryDirectoryFile (get_handle (), NULL, NULL, NULL, &io, - d_cache (dir), DIR_BUF_SIZE, - (dir->__flags & dirent_nfs_d_ino) - ? FileNamesInformation - : FileDirectoryInformation, - FALSE, NULL, dir->__d_position == 0); - } - -go_ahead: - - if (status == STATUS_NO_MORE_FILES) - /*nothing*/; - else if (!NT_SUCCESS (status)) - debug_printf ("NtQueryDirectoryFile failed, status %p, win32 error %lu", - status, RtlNtStatusToDosError (status)); - else - { - buf = (PFILE_ID_BOTH_DIR_INFORMATION) (d_cache (dir) + d_cachepos (dir)); - if (buf->NextEntryOffset == 0) - d_cachepos (dir) = 0; - else - d_cachepos (dir) += buf->NextEntryOffset; - if ((dir->__flags & dirent_get_d_ino)) - { - FileName = buf->FileName; - FileNameLength = buf->FileNameLength; - FileAttributes = buf->FileAttributes; - if ((dir->__flags & dirent_set_d_ino)) - de->d_ino = buf->FileId.QuadPart; - } - else if ((dir->__flags & dirent_nfs_d_ino)) - { - FileName = ((PFILE_NAMES_INFORMATION) buf)->FileName; - FileNameLength = ((PFILE_NAMES_INFORMATION) buf)->FileNameLength; - } - else - { - FileName = ((PFILE_DIRECTORY_INFORMATION) buf)->FileName; - FileNameLength = ((PFILE_DIRECTORY_INFORMATION) buf)->FileNameLength; - FileAttributes = ((PFILE_DIRECTORY_INFORMATION) buf)->FileAttributes; - } - RtlInitCountedUnicodeString (&fname, FileName, FileNameLength); - de->d_ino = d_mounts (dir)->check_mount (&fname, de->d_ino); - if (de->d_ino == 0 && (dir->__flags & dirent_set_d_ino)) - { - /* Don't try to optimize relative to dir->__d_position. On several - filesystems it's no safe bet that "." and ".." entries always - come first. */ - if (FileNameLength == sizeof (WCHAR) && FileName[0] == '.') - de->d_ino = get_ino_by_handle (pc, get_handle ()); - else if (FileNameLength == 2 * sizeof (WCHAR) - && FileName[0] == L'.' && FileName[1] == L'.') - { - if (!(dir->__flags & dirent_isroot)) - de->d_ino = readdir_get_ino (get_name (), true); - else - de->d_ino = get_ino_by_handle (pc, get_handle ()); - } - else - { - OBJECT_ATTRIBUTES attr; - HANDLE hdl; - NTSTATUS f_status; - - InitializeObjectAttributes (&attr, &fname, - pc.objcaseinsensitive (), - get_handle (), NULL); - /* FILE_OPEN_REPARSE_POINT on NFS is a no-op, so the normal - NtOpenFile here returns the inode number of the symlink target, - rather than the inode number of the symlink itself. - - Worse, trying to open a symlink without setting the special - "ActOnSymlink" EA triggers a bug in Windows 7 which results - in a timeout of up to 20 seconds, followed by two exceptions - in the NT kernel. - - Since both results are far from desirable, we open symlinks - on NFS so that we get the right inode and a happy W7. - And, since some filesystems choke on the EAs, we don't - use them unconditionally. */ - f_status = (dir->__flags & dirent_nfs_d_ino) - ? NtCreateFile (&hdl, READ_CONTROL, &attr, &io, - NULL, 0, FILE_SHARE_VALID_FLAGS, - FILE_OPEN, FILE_OPEN_FOR_BACKUP_INTENT, - &nfs_aol_ffei, sizeof nfs_aol_ffei) - : NtOpenFile (&hdl, READ_CONTROL, &attr, &io, - FILE_SHARE_VALID_FLAGS, - FILE_OPEN_FOR_BACKUP_INTENT - | FILE_OPEN_REPARSE_POINT); - if (NT_SUCCESS (f_status)) - { - de->d_ino = get_ino_by_handle (pc, hdl); - NtClose (hdl); - } - } - /* Untrusted file system. Don't try to fetch inode number again. */ - if (de->d_ino == 0) - dir->__flags &= ~dirent_set_d_ino; - } - } - - if (!(res = readdir_helper (dir, de, RtlNtStatusToDosError (status), - buf ? FileAttributes : 0, &fname))) - dir->__d_position++; - else if (!(dir->__flags & dirent_saw_dot)) - { - strcpy (de->d_name , "."); - de->d_ino = get_ino_by_handle (pc, get_handle ()); - dir->__d_position++; - dir->__flags |= dirent_saw_dot; - res = 0; - } - else if (!(dir->__flags & dirent_saw_dot_dot)) - { - strcpy (de->d_name , ".."); - if (!(dir->__flags & dirent_isroot)) - de->d_ino = readdir_get_ino (get_name (), true); - else - de->d_ino = get_ino_by_handle (pc, get_handle ()); - dir->__d_position++; - dir->__flags |= dirent_saw_dot_dot; - res = 0; - } - - syscall_printf ("%d = readdir (%p, %p) (L\"%lS\" > \"%ls\")", res, dir, &de, - res ? NULL : &fname, res ? "***" : de->d_name); - return res; -} - -_off64_t -fhandler_disk_file::telldir (DIR *dir) -{ - return dir->__d_position; -} - -void -fhandler_disk_file::seekdir (DIR *dir, _off64_t loc) -{ - rewinddir (dir); - while (loc > dir->__d_position) - if (!::readdir (dir)) - break; -} - -void -fhandler_disk_file::rewinddir (DIR *dir) -{ - d_cachepos (dir) = 0; - if (wincap.has_buggy_restart_scan () && isremote ()) - { - /* This works around a W2K bug. The RestartScan parameter in calls - to NtQueryDirectoryFile on remote shares is ignored, thus - resulting in not being able to rewind on remote shares. By - reopening the directory, we get a fresh new directory pointer. */ - OBJECT_ATTRIBUTES attr; - NTSTATUS status; - IO_STATUS_BLOCK io; - HANDLE new_dir; - - InitializeObjectAttributes (&attr, &ro_u_empty, pc.objcaseinsensitive (), - get_handle (), NULL); - status = NtOpenFile (&new_dir, SYNCHRONIZE | FILE_LIST_DIRECTORY, - &attr, &io, FILE_SHARE_VALID_FLAGS, - FILE_SYNCHRONOUS_IO_NONALERT - | FILE_OPEN_FOR_BACKUP_INTENT - | FILE_DIRECTORY_FILE); - if (!NT_SUCCESS (stat)) - debug_printf ("Unable to reopen dir %s, NT error: %p", - get_name (), status); - else - { - NtClose (get_handle ()); - set_io_handle (new_dir); - } - } - dir->__d_position = 0; - d_mounts (dir)->rewind (); -} - -int -fhandler_disk_file::closedir (DIR *dir) -{ - int res = 0; - NTSTATUS status; - - delete d_mounts (dir); - if (!get_handle ()) - /* ignore */; - else if (get_handle () == INVALID_HANDLE_VALUE) - { - set_errno (EBADF); - res = -1; - } - else if (!NT_SUCCESS (status = NtClose (get_handle ()))) - { - __seterrno_from_nt_status (status); - res = -1; - } - syscall_printf ("%d = closedir (%p, %s)", res, dir, get_name ()); - return res; -} - -fhandler_cygdrive::fhandler_cygdrive () : - fhandler_disk_file (), ndrives (0), pdrive (NULL) -{ -} - -int -fhandler_cygdrive::open (int flags, mode_t mode) -{ - if ((flags & (O_CREAT | O_EXCL)) == (O_CREAT | O_EXCL)) - { - set_errno (EEXIST); - return 0; - } - if (flags & O_WRONLY) - { - set_errno (EISDIR); - return 0; - } - flags |= O_DIROPEN; - set_flags (flags); - nohandle (true); - return 1; -} - -int -fhandler_cygdrive::close () -{ - return 0; -} - -void -fhandler_cygdrive::set_drives () -{ - pdrive = pdrive_buf; - ndrives = GetLogicalDriveStrings (sizeof pdrive_buf, pdrive_buf) / DRVSZ; -} - -int -fhandler_cygdrive::fstat (struct __stat64 *buf) -{ - fhandler_base::fstat (buf); - buf->st_ino = 2; - buf->st_mode = S_IFDIR | S_IXUSR | S_IXGRP | S_IXOTH; - if (!ndrives) - set_drives (); - char flptst[] = "X:"; - int n = ndrives; - for (const char *p = pdrive; p && *p; p = strchr (p, '\0') + 1) - if (is_floppy ((flptst[0] = *p, flptst)) - || GetFileAttributes (p) == INVALID_FILE_ATTRIBUTES) - n--; - buf->st_nlink = n + 2; - return 0; -} - -DIR * -fhandler_cygdrive::opendir (int fd) -{ - DIR *dir; - - dir = fhandler_disk_file::opendir (fd); - if (dir && !ndrives) - set_drives (); - - return dir; -} - -int -fhandler_cygdrive::readdir (DIR *dir, dirent *de) -{ - char flptst[] = "X:"; - - while (true) - { - if (!pdrive || !*pdrive) - { - if (!(dir->__flags & dirent_saw_dot)) - { - de->d_name[0] = '.'; - de->d_name[1] = '\0'; - de->d_ino = 2; - } - return ENMFILE; - } - if (!is_floppy ((flptst[0] = *pdrive, flptst)) - && GetFileAttributes (pdrive) != INVALID_FILE_ATTRIBUTES) - break; - pdrive = strchr (pdrive, '\0') + 1; - } - *de->d_name = cyg_tolower (*pdrive); - de->d_name[1] = '\0'; - user_shared->warned_msdos = true; - de->d_ino = readdir_get_ino (pdrive, false); - dir->__d_position++; - pdrive = strchr (pdrive, '\0') + 1; - syscall_printf ("%p = readdir (%p) (%s)", &de, dir, de->d_name); - return 0; -} - -void -fhandler_cygdrive::rewinddir (DIR *dir) -{ - pdrive = pdrive_buf; - dir->__d_position = 0; -} - -int -fhandler_cygdrive::closedir (DIR *dir) -{ - pdrive = pdrive_buf; - return 0; -} |