Changeset 13225 for trunk/Mars


Ignore:
Timestamp:
03/26/12 09:06:59 (13 years ago)
Author:
tbretz
Message:
Do not read more than the expected number of rows per default.
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/Mars/mcore/fits.h

    r12996 r13225  
    619619    }
    620620
    621     bool GetRow(size_t row)
    622     {
     621    bool GetRow(size_t row, bool check=true)
     622    {
     623        if (check && row>=fTable.num_rows)
     624            return false;
     625
    623626        const uint8_t offset = ReadRow(row);
    624627        if (!good())
     
    648651    }
    649652
    650     bool GetNextRow()
    651     {
    652         return GetRow(fRow+1);
     653    bool GetNextRow(bool check=true)
     654    {
     655        return GetRow(fRow+1, check);
    653656    }
    654657
Note: See TracChangeset for help on using the changeset viewer.