Skip to content

Commit

Permalink
fix up const_cast warning
Browse files Browse the repository at this point in the history
  • Loading branch information
hobu committed Apr 16, 2013
1 parent d7a238f commit d652cd3
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions include/pdal/PointBuffer.hpp
Expand Up @@ -254,7 +254,7 @@ class PDAL_DLL PointBuffer
/// @param pointIndex position to start accessing
inline boost::uint8_t* getData(boost::uint32_t pointIndex) const
{
return (boost::uint8_t*)&(m_data.front()) + m_byteSize * pointIndex;
return const_cast<boost::uint8_t*>(&(m_data.front())) + m_byteSize * pointIndex;
}

/// copies the raw data into your own byte array and sets the size
Expand Down Expand Up @@ -348,7 +348,6 @@ class PDAL_DLL PointBuffer
std::vector<boost::uint8_t> m_data;
boost::uint32_t m_numPoints;
boost::uint32_t m_capacity;
boost::uint64_t m_arraySize;
Bounds<double> m_bounds;

// We cache m_schema.getByteSize() here because it would end up
Expand Down

0 comments on commit d652cd3

Please sign in to comment.