reticulatedpines / magiclantern_simplified

A Git based version of Magic Lantern, for those unwilling or unable to work using Mercurial. The vast majority of branches have been removed, with those thought to be important brought in individually and merged.
GNU General Public License v2.0
142 stars 50 forks source link

bmp: don't provide invalid handle to XCM_GetSourceSurface #58

Closed coon42 closed 2 years ago

coon42 commented 2 years ago

This fixes spamming [WINSYS] ERROR XCM_GetSourceSurface Illegal handle when booting a camera in factory mode without having display attached where XCM gets not initialized.

kitor commented 2 years ago

Use case is invalid as ML requires GUI to boot (it will wait for vram pointer in a loop). But this change may reduce a number of winsys messages on regular boot.

reticulatedpines commented 2 years ago

Do we want this change? The comments make me unsure. How would I test this on cams with display attached? It should work unchanged compared to before I guess?

kitor commented 2 years ago

We discussed that on Discord and the conclusion was that ML is not suited to run in "factory mode" anyway so it makes no sense, as whole Magic Lantern code is dependent on having working display/drawing routines.

In a normal run this change will silence a few prints from that function (it will print error until XCM is initialized).

coon42 commented 2 years ago

We probably shouldn't merge this. I Will just use this locally when booting into factory mode.