[Liblas-devel] liblas throwing an error upon wrong day of the
year on "corrupt" LAS file
Howard Butler
hobu.inc at gmail.com
Mon Apr 4 10:27:28 EDT 2011
On Apr 4, 2011, at 7:04 AM, Martin Isenburg wrote:
>> Anyhow the problem was easily solved by changing the code in header.cpp
>> Ciao
>> Francesco
>
> But it should be fixed in the main release. I see a Y10K bug looming ... (-;
>
> 337 void Header::SetCreationYear(uint16_t v)
> 338 {
> 339 // mloskot: I've taken these values arbitrarily
> 340 if (v > 9999)
> 341 throw std::out_of_range("year out of range");
> 342
> 343 m_createYear = v;
> 344 }
I agree. These limits should be enforced by the user, not the library.
http://trac.liblas.org/ticket/221
Howard
More information about the Liblas-devel
mailing list