Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Minor bugfixes

  • Loading branch information...
commit 62fe15d31bc8061948ce6ccb52d8c5e58e076f9b 1 parent 93dcd7b
Adam Nielsen authored
2  include/camoto/gamegraphics/tileset.hpp
View
@@ -151,7 +151,7 @@ class Tileset: virtual public Metadata {
/**
* @note To implementors: This function defaults to triggering an
* assertion failure, so this function only needs to be overridden if
- * there are sub-tilesets available.
+ * there are sub-images available.
*
* @param id
* ID of the item to open, as returned by getItems().
2  src/img-magick.cpp
View
@@ -73,7 +73,7 @@ StdImageDataPtr MagickImage::toStandard()
unsigned long dataSize = width * height;
uint8_t *imgData = new uint8_t[dataSize];
StdImageDataPtr ret(imgData);
- for (dataSize++; dataSize > 0; dataSize--) *imgData++ = *pixels++;
+ while (dataSize-- > 0) *imgData++ = *pixels++;
return ret;
} catch (Magick::Exception& e) {
3  src/tls-pcx.cpp
View
@@ -18,6 +18,7 @@
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
+#include <boost/shared_array.hpp>
#include "img-magick.hpp"
#include "tls-pcx.hpp"
@@ -39,7 +40,7 @@ PCXTileset::PCXTileset(iostream_sptr data, FN_TRUNCATE fnTruncate,
unsigned long lenData = this->data->tellg();
this->data->seekg(0, std::ios::beg);
- boost::shared_ptr<uint8_t> imgData(new uint8_t[lenData]);
+ boost::shared_array<uint8_t> imgData(new uint8_t[lenData]);
this->data->read((char *)imgData.get(), lenData);
try {
Please sign in to comment.
Something went wrong with that request. Please try again.