diff options
author | Christopher Faylor <me@cgf.cx> | 2005-09-08 00:57:12 +0000 |
---|---|---|
committer | Christopher Faylor <me@cgf.cx> | 2005-09-08 00:57:12 +0000 |
commit | 70d0243ce9d627f9aa79b3eccbf0747347ba7b1a (patch) | |
tree | 7e10b238e159c210753c54b9fa80c995d15e9293 /winsup/cygwin/path.h | |
parent | 31fcc87ed9625fef64c1147f81190eebc6c32bb4 (diff) | |
download | cygnal-70d0243ce9d627f9aa79b3eccbf0747347ba7b1a.tar.gz cygnal-70d0243ce9d627f9aa79b3eccbf0747347ba7b1a.tar.bz2 cygnal-70d0243ce9d627f9aa79b3eccbf0747347ba7b1a.zip |
* hookapi.cc (rvadelta): Change argument to DWORD to eliminate a compiler
warning.
* path.h (path_conv::set_cygexec): New function.
* spawn.cc (av::iscygwin): Eliminate.
(av::av): Don't initialize iscygwin.
(spawn_guts): Just use real_path.iscygexec for all tests.
(av::fixup): Short circuit test if .exe extension and known cygexec. Set
cygexec flag appropriately if we find that program uses cygwin1.dll.
Diffstat (limited to 'winsup/cygwin/path.h')
-rw-r--r-- | winsup/cygwin/path.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/winsup/cygwin/path.h b/winsup/cygwin/path.h index a502e8629..14c23ebe5 100644 --- a/winsup/cygwin/path.h +++ b/winsup/cygwin/path.h @@ -151,6 +151,13 @@ class path_conv int is_lnk_special () const {return is_fs_device () || isfifo () || is_lnk_symlink ();} int issocket () const {return dev.devn == FH_UNIX;} int iscygexec () const {return path_flags & PATH_CYGWIN_EXEC;} + void set_cygexec (bool isset) + { + if (isset) + path_flags |= PATH_CYGWIN_EXEC; + else + path_flags &= ~PATH_CYGWIN_EXEC; + } bool isro () const {return !!(path_flags & PATH_RO);} bool exists () const {return fileattr != INVALID_FILE_ATTRIBUTES;} bool has_attribute (DWORD x) const {return exists () && (fileattr & x);} |