Skip to content

Commit

Permalink
xrGame/GamePersistent.cpp: dedicated server crash fix
Browse files Browse the repository at this point in the history
xrNetServer/ip_filter.cpp: replaced size() == 0 with empty()
  • Loading branch information
Xottab-DUTY committed Jul 12, 2018
1 parent da41e6e commit 3607bdc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion src/xrGame/GamePersistent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,8 @@ CGamePersistent::~CGamePersistent(void)

void CGamePersistent::PreStart(LPCSTR op)
{
pApp->SetLoadingScreen(new UILoadingScreen());
if (!GEnv.isDedicatedServer)
pApp->SetLoadingScreen(new UILoadingScreen());
inherited::PreStart(op);
}

Expand Down
2 changes: 1 addition & 1 deletion src/xrNetServer/ip_filter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ u32 ip_filter::load()

bool ip_filter::is_ip_present(u32 ip_address)
{
if (m_all_subnets.size() == 0)
if (m_all_subnets.empty())
return true;
subnet_item tmp_fake_item;
hton_bo(ip_address, tmp_fake_item);
Expand Down

0 comments on commit 3607bdc

Please sign in to comment.