mirror of
https://github.com/KartKrewDev/RingRacers.git
synced 2025-10-30 08:01:28 +00:00
Merge branch 'profile-startup-save' into 'master'
Profile I_Error on Startup fix (resolves #451) Closes #451 See merge request KartKrew/Kart!974
This commit is contained in:
commit
3cf12d42b2
1 changed files with 6 additions and 0 deletions
|
|
@ -219,6 +219,12 @@ void PR_SaveProfiles(void)
|
||||||
UINT8 i, j, k;
|
UINT8 i, j, k;
|
||||||
savebuffer_t save = {0};
|
savebuffer_t save = {0};
|
||||||
|
|
||||||
|
if (profilesList[PROFILE_GUEST] == NULL)
|
||||||
|
{
|
||||||
|
// Profiles have not been loaded yet, don't overwrite with garbage.
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (P_SaveBufferAlloc(&save, sizeof(UINT32) + (numprofiles * sizeof(profile_t))) == false)
|
if (P_SaveBufferAlloc(&save, sizeof(UINT32) + (numprofiles * sizeof(profile_t))) == false)
|
||||||
{
|
{
|
||||||
I_Error("No more free memory for saving profiles\n");
|
I_Error("No more free memory for saving profiles\n");
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue