diff options
author | 2016-01-13 11:11:33 -0500 | |
---|---|---|
committer | 2016-01-13 11:11:33 -0500 | |
commit | 61dd670bb4b950f96002ea529235ac341c21a12e (patch) | |
tree | 169ad65aa11e1fb5916492027e3f78ee37e254c4 | |
parent | 7baa5bda9175ed515ba9507236303589cd731a56 (diff) |
fixed the permission on the console directory (now creates with 777)
-rwxr-xr-x | scripts/automation/trex_control_plane/console/trex_console.py | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/scripts/automation/trex_control_plane/console/trex_console.py b/scripts/automation/trex_control_plane/console/trex_console.py index 8c823e8c..450feb6a 100755 --- a/scripts/automation/trex_control_plane/console/trex_console.py +++ b/scripts/automation/trex_control_plane/console/trex_console.py @@ -66,7 +66,14 @@ class TRexGeneralCmd(cmd.Cmd): def save_console_history(self): if not os.path.exists(self._history_file_dir): - os.makedirs(self._history_file_dir) + # make the directory available for every user + try: + original_umask = os.umask(0) + os.makedirs(self._history_file_dir, mode = 0777) + finally: + os.umask(original_umask) + + # os.mknod(self._history_file) readline.write_history_file(self._history_file) return |