diff options
author | Bardur Arantsson <bardur@scientician.net> | 2014-06-26 21:54:30 +0200 |
---|---|---|
committer | Bardur Arantsson <bardur@scientician.net> | 2014-06-27 07:42:41 +0200 |
commit | f50ed5b5c1e3caa38a5409cc22ea53fefd5c1209 (patch) | |
tree | 827ac3d7301849f2608dba0c1465d65137fffd94 /src/quark.cc | |
parent | 143808187704f8feec1b71f4e1c9a4b7efb1d9d6 (diff) |
Remove most of z-virt.[ch]
This commit leaves only safe_calloc() as a convenient "non-failing"
calloc().
Diffstat (limited to 'src/quark.cc')
-rw-r--r-- | src/quark.cc | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/quark.cc b/src/quark.cc index 1c8619fa..8a78b6f8 100644 --- a/src/quark.cc +++ b/src/quark.cc @@ -49,6 +49,8 @@ void quark_init() */ s16b quark_add(cptr str) { + assert(str != nullptr); + int i; /* Look for an existing quark */ @@ -65,7 +67,7 @@ s16b quark_add(cptr str) quark__num = i + 1; /* Add a new quark */ - quark__str[i] = string_make(str); + quark__str[i] = strdup(str); /* Return the index */ return (i); |