Skip to content

Commit 7ff8e9f

Browse files
committed
Fixed a path in auth.paths. Commented out storing the user settings database due to a buffer overflow issue.
1 parent ddfea6f commit 7ff8e9f

File tree

2 files changed

+5
-4
lines changed

2 files changed

+5
-4
lines changed

addons/source-python/packages/source-python/auth/paths.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,7 @@
1212
# >> GLOBAL VARIABLES
1313
# =============================================================================
1414
# Store the path to the auth providers
15-
AUTH_PROVIDER_PATH = _SP_PACKAGES_PATH.joinpath(
16-
'packages', 'source-python', 'auth', 'providers')
15+
AUTH_PROVIDER_PATH = _SP_PACKAGES_PATH.joinpath('auth', 'providers')
1716

1817
# Store the path to the auth configurations
1918
AUTH_CFG_PATH = _CFG_PATH.joinpath('auth_providers')

addons/source-python/packages/source-python/settings/storage.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ def __init__(self, default_factory):
3434
if _STORAGE_PATH.isfile():
3535

3636
# Open/close the settings database
37-
with _STORAGE_PATH.open('rb') as _user_settings:
37+
with _STORAGE_PATH.open('r') as _user_settings:
3838

3939
# Load the database into the dictionary
4040
super(_PlayerSettingsDictionary, self).__init__(
@@ -49,11 +49,13 @@ def __init__(self, default_factory):
4949
def server_spawn(self, game_event):
5050
'''Stores the dictionary to the database on map change'''
5151

52+
"""
5253
# Open/close the settings database as write
53-
with _STORAGE_PATH.open('wb') as _user_settings:
54+
with _STORAGE_PATH.open('w') as _user_settings:
5455
5556
# Dump the dictionary to the database file
5657
pickle.dump(self, _user_settings)
58+
"""
5759

5860
# Get the _PlayerSettingsDictionary instance
5961
_PlayerSettingsStorage = _PlayerSettingsDictionary(dict)

0 commit comments

Comments
 (0)