Skip to content

Out of bounds access in DoGFF() #7

Description

@kettenis

Hi Ivan,

Suma Murthy is hitting an out-of-bounds array access in DoGFF() when trying to PolConvert some EVN data. This happens at:

AbsP = std::abs(Temp[m][time[m][l]*Nchan[i] + nu[m][k]]);

There is some guesswork involved, but I think time[n][1] is Nchan[i]-1 here because we hit:

if (time[m][1]==0){time[m][0]=Nchan[i]-1;} else{time[m][0]=time[m][1]-1;};

This results in an array index of the order of Nchan[i]*Nchan[i] which is clearly larger than intended. So I think there is something wrong in the logic around L1522. The reason Suma hits this here may very well be because this data set has 16K channels. It may very well be that you don't hit this with data sets with less channels. But it would still do the wrong thing.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions