[openjk] 18/130: Fix cast_io_buffer usage
Simon McVittie
smcv at debian.org
Fri Oct 28 11:09:12 UTC 2016
This is an automated email from the git hooks/post-receive script.
smcv pushed a commit to branch debian/master
in repository openjk.
commit 5ce400adcc221d589d39048c9223a98d15c510f6
Author: bibendovsky <bibendovsky at NOSTROMO>
Date: Sun Jul 3 23:37:17 2016 +0300
Fix cast_io_buffer usage
---
shared/qcommon/ojk_sg_archive.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/shared/qcommon/ojk_sg_archive.h b/shared/qcommon/ojk_sg_archive.h
index 64ec1fb..d18ac03 100644
--- a/shared/qcommon/ojk_sg_archive.h
+++ b/shared/qcommon/ojk_sg_archive.h
@@ -58,7 +58,7 @@ void Archive::accomodate_io_buffer(
template<typename T>
T Archive::cast_io_buffer()
{
- return reinterpret_cast<T>(&io_buffer_[io_buffer_offset_]);
+ return reinterpret_cast<T>(io_buffer_[io_buffer_offset_]);
}
template<typename T>
@@ -340,7 +340,7 @@ void Archive::read(
dst_count);
std::uninitialized_copy_n(
- cast_io_buffer<const TDst*>(),
+ &cast_io_buffer<const TDst&>(),
dst_count,
dst_values);
@@ -544,7 +544,7 @@ void Archive::write(
std::uninitialized_copy_n(
src_values,
src_count,
- cast_io_buffer<TSrc*>());
+ &cast_io_buffer<TSrc&>());
// FIXME Byte order
//
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-games/openjk.git
More information about the Pkg-games-commits
mailing list