Import from Suunto Cobra TC not possible

Dirk Hohndel dirk at hohndel.org
Sat Feb 15 06:28:26 UTC 2014


On Sat, 2014-02-15 at 08:11 +0100, Jef Driesen wrote:
> On 14-02-14 17:06, Wolfgang Uhl wrote:
> > wow, that's quick response!
> 
> Answering emails is easy. Fixing the problem usually takes a bit longer :-)
> 
> > Allright, i only enabled logfile, but not dump and
> > started the import again, please find the logfile attached.
> 
> Ok, this seems to be the same problem as reported for the Suunto Zoop a few days 
> ago. The logfile you send me shows a full dump was downloaded, and not the dives.
> 
> @Dirk: I downloaded the Subsurface v4.0.2 Windows binary, and I can confirm the 
> problem. When I start subsurface (with an empty file), go straight to the dive 
> computer download dialog and try to download dives, subsurface will download a 
> full memory dump instead of the dives. This is with both logfile and dumpfile 
> disabled. (For completeness, I canceled before the download has finished, such 
> that the download window isn't closed.)
> 
> If I now check the dumpfile option, and try again, it downloads a memory dump as 
> expected. (Again I canceled.) But if I now uncheck the dumpfile option and try 
> one last time, the dives are starting to download.
> 
> So there is definitely something wrong with the Windows binary on the website. 
> I'm unable to reproduce this on linux (with a self compiled binary from tag v4.0.2).

This appears to be the difference between a debug build (where
apparently gcc helpfully initializes members of classes in the default
constructor to all 0), vs. release bulds (where it doesn't do that).

So whenever I try to debug this, everything looks fine. But the release
binary shows the problem. I haven't found documentation that confirms
that this is what gcc is doing, but either way, re-reading the offending
code immediately showed that we were indeed not correctly initializing
the dump and log flags.

I've uploaded a new Windows binary and asked the people who reported
this bug to re-test. And I'll push the change to both the v4.0-branch
and master in a moment, so Wolfgang can test as well.

/D



More information about the subsurface mailing list