Skip to content

Null event buffer causes a segfault (Linux) #161

@drfailer

Description

@drfailer

Context

  • OpenEB version: 4.6.2 (this part of the code is the same in the newer versions)
  • Camera: SilkEVCam HD (sensor: IMX636(Sony))
  • Program:

I'm working on a bias tuning program that captures events during 3 seconds, make some adjustments, and loops until the optimizer converges. The callback only captures and saves the events in a map. After a certain amount of time, the program segfaults.

Origin

auto ev_buffer = i_events_stream_->get_latest_raw_data();

Using gdb, I found that the segfault comes from the LivePrivate::process_impl function. Despite the fact that i_events_stream_->wait_next_buffer() returns 1, i_events_stream_->get_latest_raw_data() returns a null pointer, and since the value of the pointer is not checked afterward, the program crashes.

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions