diff options
author | Bardur Arantsson <bardur@scientician.net> | 2016-06-20 22:49:05 +0200 |
---|---|---|
committer | Bardur Arantsson <bardur@scientician.net> | 2016-06-20 22:49:05 +0200 |
commit | f1af5f03ccd79006fa1536e00ac699272aebc5a0 (patch) | |
tree | 75442a0379af7ea6db15b703882ae3589600cf74 /src/birth.cc | |
parent | c1f61900360d9dcd17382f37f16a75184c99844a (diff) |
Change player_type to non-POD type
Diffstat (limited to 'src/birth.cc')
-rw-r--r-- | src/birth.cc | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/birth.cc b/src/birth.cc index 188d9892..76d032f9 100644 --- a/src/birth.cc +++ b/src/birth.cc @@ -703,8 +703,7 @@ static void player_wipe(void) wipe_saved(); /* Hack -- zero the struct */ - static_assert(std::is_pod<player_type>::value, "Cannot memset non-POD type"); - memset(p_ptr, 0, sizeof(player_type)); + *p_ptr = player_type(); /* Level 1 is the first level */ p_ptr->lev = 1; |