IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Changeset 33443


Ignore:
Timestamp:
Mar 8, 2012, 3:55:18 PM (14 years ago)
Author:
bills
Message:

Fail if a negative sequence number is found in a cmf file.
This prevents a SEGV. We have seen this with corrupted cmf files

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/psModules/src/objects/pmSourceIO.c

    r32977 r33443  
    10691069                for (long i = sources->n -1; i >= 0; i--) {
    10701070                    pmSource *source = sources->data[i];
     1071                    if (source->seq < 0) {
     1072                        // This can happen cmf files that have been corrupted
     1073                        psError(PS_ERR_IO, true, "seq < 0 for source %ld in %s", i, file->origname);
     1074                        return false;
     1075                    }
    10711076                    if (source->seq > seq_max) {
    10721077                        seq_max = source->seq;
Note: See TracChangeset for help on using the changeset viewer.