Crash on exit when releasing Decklink* after closing window

Ask software engineering and SDK questions for developers working on Mac OS X, Windows or Linux.
  • Author
  • Message
Offline

EricRenaudHoude

  • Posts: 2
  • Joined: Mon Nov 14, 2016 4:09 pm

Crash on exit when releasing Decklink* after closing window

PostMon Nov 14, 2016 4:20 pm

This error occurs on Windows. My code is based on the CapturePreview sample.

If I stop or release a Decklink device (IDeckLinkInputCallback), or a DecklinkDiscovery object (IDeckLinkDeviceNotificationCallback) after my application window has been closed, I reliably get an access violation crash, even though the object pointers are not NULL. Is there any possibility that the Blackmagic SDK relies on Windows OS event that interferes with my destruction order?

Any ideas?
Offline

EricRenaudHoude

  • Posts: 2
  • Joined: Mon Nov 14, 2016 4:09 pm

Re: Crash on exit when releasing Decklink* after closing win

PostMon Nov 14, 2016 9:20 pm

I'm able to replicate the issue in the sample by moving the CCapturePreviewDlg::OnClose() implementation to a destructor: read access violation on m_deckLinkInput.

In my application, I can also connect my release calls to a closed window signal. However even after doing so, I still get rare occasional crashes on exit for some reason.

Return to Software Developers

Who is online

Users browsing this forum: No registered users and 27 guests