* Use new unified status_flag accessor methods from classes fhandler_*,
tty_min, mtinfo and fs_info thoroughout. * fhandler.h: Redefine all set_close_on_exec methods to take a bool argument. (enum conn_state): Rename from connect_state. (class fhandler_base): Rename some status flags to align with accessor method names. Drop encoded flag entirely. Unify status accessor methods. Const'ify all read accessor methods. (class fhandler_socket): Ditto. (class fhandler_dev_raw): Ditto. * fhandler_disk_file.cc (fhandler_base::fstat_fs): Use fs.fs_is_fat() instead of evaluating FATness of file system here. (fhandler_disk_file::opendir): Drop call to set_encoded(). (fhandler_disk_file::readdir): Use pc.isencoded() directly. * mtinfo.h (class mtinfo_drive): Const'ify all read accessor methods. * path.cc (fsinfo_cnt): Add. (fs_info::update): Accomodate class changes. Evaluate file system name specific flags right here. Add thread safety for reading and writing global fsinfo array. * path.h (enum path_types): Drop values for flags kept in fs already. (struct fs_info): Move status informatin into private struct type status_flags. Add accessor methods. Remove path and file system name string arrays in favor of status bits. (class path_conv): Use new fs_info status information where appropriate. (path_conf::fs_has_ea): Rename from fs_fast_ea. (path_conf::fs_has_acls): New method. (path_conf::root_dir): Remove. (path_conf::volname): Remove. * syscalls (statfs): Evaluate root dir locally. * tty.h (class tty_min): Unify status accessor methods. Const'ify all read accessor methods.
This commit is contained in:
@@ -113,18 +113,18 @@ public:
|
||||
int ioctl (HANDLE mt, unsigned int cmd, void *buf);
|
||||
int set_pos (HANDLE mt, int mode, long count, bool sfm_func);
|
||||
|
||||
bool buffer_writes () const { return status.buffer_writes; }
|
||||
void buffer_writes (bool b) { status.buffer_writes = b; }
|
||||
bool buffer_writes () { return status.buffer_writes; }
|
||||
bool two_fm () const { return status.two_fm; }
|
||||
void two_fm (bool b) { status.two_fm = b; }
|
||||
bool two_fm () { return status.two_fm; }
|
||||
bool fast_eom () const { return status.fast_eom; }
|
||||
void fast_eom (bool b) { status.fast_eom = b; }
|
||||
bool fast_eom () { return status.fast_eom; }
|
||||
bool auto_lock () const { return status.auto_lock; }
|
||||
void auto_lock (bool b) { status.auto_lock = b; }
|
||||
bool auto_lock () { return status.auto_lock; }
|
||||
bool sysv () const { return status.sysv; }
|
||||
void sysv (bool b) { status.sysv = b; }
|
||||
bool sysv () { return status.sysv; }
|
||||
bool nowait () const { return status.nowait; }
|
||||
void nowait (bool b) { status.nowait = b; }
|
||||
bool nowait () { return status.nowait; }
|
||||
PTAPE_GET_DRIVE_PARAMETERS dp (void) { return &_dp; }
|
||||
PTAPE_GET_MEDIA_PARAMETERS mp (void) { return &_mp; }
|
||||
mtinfo_part *part (int num) { return &_part[num]; }
|
||||
|
Reference in New Issue
Block a user