mirror of
https://github.com/EQEmu/Server.git
synced 2025-12-13 06:21:28 +00:00
[Hotfix] Fixed Mail Key Bug (#5015)
* [Hotfix] Fixed Mail Key Bug * Release
This commit is contained in:
parent
4b69df646c
commit
1575a2af40
@ -1,3 +1,8 @@
|
|||||||
|
## [23.10.1] 9/16/2025
|
||||||
|
|
||||||
|
### Hotfix
|
||||||
|
* Fixed Mail Key Bug ([#5015](https://github.com/EQEmu/Server/pull/5015)) @Kinglykrab 2025-09-16
|
||||||
|
|
||||||
## [23.10.0] 9/15/2025
|
## [23.10.0] 9/15/2025
|
||||||
|
|
||||||
### Build
|
### Build
|
||||||
|
|||||||
@ -122,7 +122,7 @@ bool SharedDatabase::SetGMFlymode(uint32 account_id, uint8 flymode)
|
|||||||
return a.id > 0;
|
return a.id > 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SharedDatabase::SetMailKey(uint32 character_id, int ip_address, int mail_key)
|
void SharedDatabase::SetMailKey(uint32 character_id, uint32 ip_address, uint32 mail_key)
|
||||||
{
|
{
|
||||||
std::string full_mail_key;
|
std::string full_mail_key;
|
||||||
|
|
||||||
@ -133,6 +133,10 @@ void SharedDatabase::SetMailKey(uint32 character_id, int ip_address, int mail_ke
|
|||||||
}
|
}
|
||||||
|
|
||||||
auto e = CharacterDataRepository::FindOne(*this, character_id);
|
auto e = CharacterDataRepository::FindOne(*this, character_id);
|
||||||
|
if (!e.id) {
|
||||||
|
LogError("Failed to find character_id [{}] when setting mailkey", character_id);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
e.mailkey = full_mail_key;
|
e.mailkey = full_mail_key;
|
||||||
|
|
||||||
@ -422,7 +426,7 @@ bool SharedDatabase::DeleteSharedBankSlot(uint32 char_id, int16 slot_id)
|
|||||||
int32 SharedDatabase::GetSharedPlatinum(uint32 account_id)
|
int32 SharedDatabase::GetSharedPlatinum(uint32 account_id)
|
||||||
{
|
{
|
||||||
const auto& e = AccountRepository::FindOne(*this, account_id);
|
const auto& e = AccountRepository::FindOne(*this, account_id);
|
||||||
|
|
||||||
return e.sharedplat;
|
return e.sharedplat;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -84,7 +84,7 @@ public:
|
|||||||
bool GetCommandSubSettings(std::vector<CommandSubsettingsRepository::CommandSubsettings> &command_subsettings);
|
bool GetCommandSubSettings(std::vector<CommandSubsettingsRepository::CommandSubsettings> &command_subsettings);
|
||||||
bool SetGMInvul(uint32 account_id, bool gminvul);
|
bool SetGMInvul(uint32 account_id, bool gminvul);
|
||||||
bool SetGMFlymode(uint32 account_id, uint8 flymode);
|
bool SetGMFlymode(uint32 account_id, uint8 flymode);
|
||||||
void SetMailKey(uint32 character_id, int ip_address, int mail_key);
|
void SetMailKey(uint32 character_id, uint32 ip_address, uint32 mail_key);
|
||||||
struct MailKeys {
|
struct MailKeys {
|
||||||
std::string mail_key;
|
std::string mail_key;
|
||||||
std::string mail_key_full;
|
std::string mail_key_full;
|
||||||
|
|||||||
@ -25,7 +25,7 @@
|
|||||||
|
|
||||||
// Build variables
|
// Build variables
|
||||||
// these get injected during the build pipeline
|
// these get injected during the build pipeline
|
||||||
#define CURRENT_VERSION "23.10.0-dev" // always append -dev to the current version for custom-builds
|
#define CURRENT_VERSION "23.10.1-dev" // always append -dev to the current version for custom-builds
|
||||||
#define LOGIN_VERSION "0.8.0"
|
#define LOGIN_VERSION "0.8.0"
|
||||||
#define COMPILE_DATE __DATE__
|
#define COMPILE_DATE __DATE__
|
||||||
#define COMPILE_TIME __TIME__
|
#define COMPILE_TIME __TIME__
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "eqemu-server",
|
"name": "eqemu-server",
|
||||||
"version": "23.10.0",
|
"version": "23.10.1",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://github.com/EQEmu/Server.git"
|
"url": "https://github.com/EQEmu/Server.git"
|
||||||
|
|||||||
@ -985,7 +985,7 @@ bool Client::HandleEnterWorldPacket(const EQApplicationPacket *app) {
|
|||||||
safe_delete(outapp);
|
safe_delete(outapp);
|
||||||
|
|
||||||
// set mailkey - used for duration of character session
|
// set mailkey - used for duration of character session
|
||||||
int mail_key = EQ::Random::Instance()->Int(1, INT_MAX);
|
uint32 mail_key = EQ::Random::Instance()->Int(1, INT_MAX);
|
||||||
|
|
||||||
database.SetMailKey(charid, GetIP(), mail_key);
|
database.SetMailKey(charid, GetIP(), mail_key);
|
||||||
if (UCSServerAvailable_) {
|
if (UCSServerAvailable_) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user