* fhandler.h (fhandler_cygdrive::seekdir): Delete declaration.
(fhandler_cygdrive::seekdir): Delete. * fhandler.h (fhandler_cygdrive::iscygdrive_root): Delete method. (fhandler_cygdrive::telldir): Delete declaration. * fhandler_disk_file.cc: Remove all uses of fhandler_cygdrive::iscygdrive_root. (fhandler_disk_file::mkdir): New method. (fhandler_disk_file::rmdir): Ditto. (fhandler_cygdrive::telldir): Delete.
This commit is contained in:
		@@ -1,3 +1,18 @@
 | 
			
		||||
2005-05-19  Christopher Faylor  <cgf@timesys.com>
 | 
			
		||||
 | 
			
		||||
	* fhandler.h (fhandler_cygdrive::seekdir): Delete declaration.
 | 
			
		||||
	(fhandler_cygdrive::seekdir): Delete.
 | 
			
		||||
 | 
			
		||||
2005-05-19  Pierre Humblet  <pierre.humblet@ieee.org>
 | 
			
		||||
 | 
			
		||||
	* fhandler.h (fhandler_cygdrive::iscygdrive_root): Delete method.
 | 
			
		||||
	(fhandler_cygdrive::telldir): Delete declaration.
 | 
			
		||||
	* fhandler_disk_file.cc: Remove all uses of
 | 
			
		||||
	fhandler_cygdrive::iscygdrive_root.
 | 
			
		||||
	(fhandler_disk_file::mkdir): New method.
 | 
			
		||||
	(fhandler_disk_file::rmdir): Ditto.
 | 
			
		||||
	(fhandler_cygdrive::telldir): Delete.
 | 
			
		||||
 | 
			
		||||
2005-05-18  Christopher Faylor  <cgf@timesys.com>
 | 
			
		||||
 | 
			
		||||
	* external.cc: Move pids declaration to file scope and use less
 | 
			
		||||
 
 | 
			
		||||
@@ -106,8 +106,6 @@ enum fh_devices
 | 
			
		||||
 | 
			
		||||
  DEV_CYGDRIVE_MAJOR = 98,
 | 
			
		||||
  FH_CYGDRIVE= FHDEV (DEV_CYGDRIVE_MAJOR, 0),
 | 
			
		||||
  FH_CYGDRIVE_A= FHDEV (DEV_CYGDRIVE_MAJOR, 'a'),
 | 
			
		||||
  FH_CYGDRIVE_Z= FHDEV (DEV_CYGDRIVE_MAJOR, 'z'),
 | 
			
		||||
 | 
			
		||||
  DEV_TCP_MAJOR = 30,
 | 
			
		||||
  FH_TCP = FHDEV (DEV_TCP_MAJOR, 36),
 | 
			
		||||
 
 | 
			
		||||
@@ -678,12 +678,9 @@ class fhandler_cygdrive: public fhandler_disk_file
 | 
			
		||||
  const char *pdrive;
 | 
			
		||||
  void set_drives ();
 | 
			
		||||
 public:
 | 
			
		||||
  bool iscygdrive_root () { return !dev ().minor; }
 | 
			
		||||
  fhandler_cygdrive ();
 | 
			
		||||
  DIR *opendir ();
 | 
			
		||||
  struct dirent *readdir (DIR *);
 | 
			
		||||
  _off64_t telldir (DIR *);
 | 
			
		||||
  void seekdir (DIR *, _off64_t);
 | 
			
		||||
  void rewinddir (DIR *);
 | 
			
		||||
  int closedir (DIR *);
 | 
			
		||||
  int __stdcall fstat (struct __stat64 *buf) __attribute__ ((regparm (2)));
 | 
			
		||||
 
 | 
			
		||||
@@ -1326,8 +1326,6 @@ fhandler_cygdrive::set_drives ()
 | 
			
		||||
int
 | 
			
		||||
fhandler_cygdrive::fstat (struct __stat64 *buf)
 | 
			
		||||
{
 | 
			
		||||
  if (!iscygdrive_root ())
 | 
			
		||||
    return fhandler_disk_file::fstat (buf);
 | 
			
		||||
  buf->st_mode = S_IFDIR | 0555;
 | 
			
		||||
  if (!ndrives)
 | 
			
		||||
    set_drives ();
 | 
			
		||||
@@ -1341,7 +1339,7 @@ fhandler_cygdrive::opendir ()
 | 
			
		||||
  DIR *dir;
 | 
			
		||||
 | 
			
		||||
  dir = fhandler_disk_file::opendir ();
 | 
			
		||||
  if (dir && iscygdrive_root () && !ndrives)
 | 
			
		||||
  if (dir && !ndrives)
 | 
			
		||||
    set_drives ();
 | 
			
		||||
 | 
			
		||||
  return dir;
 | 
			
		||||
@@ -1350,8 +1348,6 @@ fhandler_cygdrive::opendir ()
 | 
			
		||||
struct dirent *
 | 
			
		||||
fhandler_cygdrive::readdir (DIR *dir)
 | 
			
		||||
{
 | 
			
		||||
  if (!iscygdrive_root ())
 | 
			
		||||
    return fhandler_disk_file::readdir (dir);
 | 
			
		||||
  if (!pdrive || !*pdrive)
 | 
			
		||||
    return NULL;
 | 
			
		||||
  if (GetFileAttributes (pdrive) == INVALID_FILE_ATTRIBUTES)
 | 
			
		||||
@@ -1369,23 +1365,9 @@ fhandler_cygdrive::readdir (DIR *dir)
 | 
			
		||||
  return dir->__d_dirent;
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
_off64_t
 | 
			
		||||
fhandler_cygdrive::telldir (DIR *dir)
 | 
			
		||||
{
 | 
			
		||||
  return fhandler_disk_file::telldir (dir);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
void
 | 
			
		||||
fhandler_cygdrive::seekdir (DIR *dir, _off64_t loc)
 | 
			
		||||
{
 | 
			
		||||
  return fhandler_disk_file::seekdir (dir, loc);
 | 
			
		||||
}
 | 
			
		||||
 | 
			
		||||
void
 | 
			
		||||
fhandler_cygdrive::rewinddir (DIR *dir)
 | 
			
		||||
{
 | 
			
		||||
  if (!iscygdrive_root ())
 | 
			
		||||
    return fhandler_disk_file::rewinddir (dir);
 | 
			
		||||
  pdrive = get_win32_name ();
 | 
			
		||||
  dir->__d_position = 0;
 | 
			
		||||
  return;
 | 
			
		||||
@@ -1394,8 +1376,6 @@ fhandler_cygdrive::rewinddir (DIR *dir)
 | 
			
		||||
int
 | 
			
		||||
fhandler_cygdrive::closedir (DIR *dir)
 | 
			
		||||
{
 | 
			
		||||
  if (!iscygdrive_root ())
 | 
			
		||||
    return fhandler_disk_file::closedir (dir);
 | 
			
		||||
  pdrive = get_win32_name ();
 | 
			
		||||
  return 0;
 | 
			
		||||
}
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user