mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
d11ea450aa
commit
6f79154dbc
@ -40,9 +40,12 @@ get_default_tempdir = tempfile.gettempdir
|
||||
|
||||
def base_dir():
|
||||
global _base_dir, _prevent_recursion
|
||||
if _base_dir is not None and not _prevent_recursion and not os.path.exists(_base_dir):
|
||||
if _base_dir is not None and not os.path.exists(_base_dir):
|
||||
# Some people seem to think that running temp file cleaners that
|
||||
# delete the temp dirs of running programs is a good idea!
|
||||
if _prevent_recursion:
|
||||
_base_dir = get_default_tempdir()
|
||||
else:
|
||||
_base_dir = None
|
||||
if _base_dir is None:
|
||||
td = os.environ.get('CALIBRE_WORKER_TEMP_DIR', None)
|
||||
|
Loading…
x
Reference in New Issue
Block a user