aboutsummaryrefslogtreecommitdiff
path: root/common/array.h
diff options
context:
space:
mode:
authorMatthew Hoops2011-08-26 22:44:17 -0400
committerMatthew Hoops2011-08-26 22:44:17 -0400
commit4a69dc13d92e82fff85dc5a3a923b74ced259ffa (patch)
tree8945cd3745fd65f28b043caf7b1beddbbce2b2a1 /common/array.h
parentad293b249e74dd1cfbdbd721d02145efbdaf9eca (diff)
parent5e174cbfe466dbbe8e5470b0a00de1481b986181 (diff)
downloadscummvm-rg350-4a69dc13d92e82fff85dc5a3a923b74ced259ffa.tar.gz
scummvm-rg350-4a69dc13d92e82fff85dc5a3a923b74ced259ffa.tar.bz2
scummvm-rg350-4a69dc13d92e82fff85dc5a3a923b74ced259ffa.zip
Merge remote branch 'upstream/master' into pegasus
Diffstat (limited to 'common/array.h')
-rw-r--r--common/array.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/common/array.h b/common/array.h
index e5434091fb..18cecfb98f 100644
--- a/common/array.h
+++ b/common/array.h
@@ -42,7 +42,7 @@ namespace Common {
* management scheme. There, only elements that 'live' are actually constructed
* (i.e., have their constructor called), and objects that are removed are
* immediately destructed (have their destructor called).
- * With Common::Array, this is not the case; instead, it simply uses new[] and
+ * With Array, this is not the case; instead, it simply uses new[] and
* delete[] to allocate whole blocks of objects, possibly more than are
* currently 'alive'. This simplifies memory management, but may have
* undesirable side effects when one wants to use an Array of complex
@@ -274,7 +274,7 @@ protected:
if (capacity) {
_storage = new T[capacity];
if (!_storage)
- ::error("Common::Array: failure to allocate %d bytes", capacity);
+ ::error("Common::Array: failure to allocate %u bytes", capacity * (uint)sizeof(T));
} else {
_storage = 0;
}