parent
8c6f18ea2a
commit
9e98097aae
|
@ -289,7 +289,6 @@ size_t ObjFileParser::getNumComponentsInDataDefinition() {
|
|||
const char* tmp( &m_DataIt[0] );
|
||||
bool end_of_definition = false;
|
||||
while ( !end_of_definition ) {
|
||||
//while( !IsLineEnd( *tmp ) ) {
|
||||
if ( isDataDefinitionEnd( tmp ) ) {
|
||||
tmp += 2;
|
||||
} else if ( IsLineEnd( *tmp ) ) {
|
||||
|
@ -420,10 +419,6 @@ static const std::string DefaultObjName = "defaultobject";
|
|||
// -------------------------------------------------------------------
|
||||
// Get values for a new face instance
|
||||
void ObjFileParser::getFace( aiPrimitiveType type ) {
|
||||
//copyNextLine(m_buffer, Buffersize);
|
||||
//char *pPtr = m_DataIt;
|
||||
//char *pPtr = m_buffer;
|
||||
//char *pEnd = &pPtr[Buffersize];
|
||||
m_DataIt = getNextToken<DataArrayIt>( m_DataIt, m_DataItEnd );
|
||||
if ( m_DataIt == m_DataItEnd || *m_DataIt == '\0' ) {
|
||||
return;
|
||||
|
@ -595,15 +590,6 @@ void ObjFileParser::getMaterialDesc() {
|
|||
// Get a comment, values will be skipped
|
||||
void ObjFileParser::getComment() {
|
||||
m_DataIt = skipLine<DataArrayIt>( m_DataIt, m_DataItEnd, m_uiLine );
|
||||
|
||||
/* while (m_DataIt != m_DataItEnd) {
|
||||
if ( '\n' == (*m_DataIt)) {
|
||||
++m_DataIt;
|
||||
break;
|
||||
} else {
|
||||
++m_DataIt;
|
||||
}
|
||||
}*/
|
||||
}
|
||||
|
||||
// -------------------------------------------------------------------
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
#pragma once
|
||||
|
||||
// Copyright (C) 2002-2007 Nikolaus Gebhardt
|
||||
// This file is part of the "Irrlicht Engine" and the "irrXML" project.
|
||||
// For conditions of distribution and use, see copyright notice in irrlicht.h and irrXML.h
|
||||
|
@ -22,6 +24,7 @@
|
|||
#include <assimp/defs.h>
|
||||
|
||||
#include "StringComparison.h"
|
||||
#include <assimp/DefaultLogger.hpp>
|
||||
|
||||
|
||||
#ifdef _MSC_VER
|
||||
|
@ -202,8 +205,12 @@ inline uint64_t strtoul10_64( const char* in, const char** out=0, unsigned int*
|
|||
|
||||
const uint64_t new_value = ( value * 10 ) + ( *in - '0' );
|
||||
|
||||
if (new_value < value) /* numeric overflow, we rely on you */
|
||||
throw std::overflow_error(std::string("Converting the string \"") + in + "\" into a value resulted in overflow.");
|
||||
// numeric overflow, we rely on you
|
||||
if ( new_value < value ) {
|
||||
DefaultLogger::get()->warn( std::string( "Converting the string \"" ) + in + "\" into a value resulted in overflow." );
|
||||
return 0;
|
||||
}
|
||||
//throw std::overflow_error();
|
||||
|
||||
value = new_value;
|
||||
|
||||
|
|
Loading…
Reference in New Issue