dive_trip_list & dive_table

Dirk Hohndel dirk at hohndel.org
Mon Apr 15 07:15:56 PDT 2013


Amit Chaudhuri <amit.k.chaudhuri at gmail.com> writes:

> Dirk,
>
> thanks for the clarification.
>
> Alt_theory: maybe the Qt ui is being initialised before the dive_table is
> written.

I am almost certain that that is the case.

> I *think* a global struct dive table would be initialised to contain PODs
> with zero value, right [1] ? This might explain my first symption of nr ==
> 0.

Yes, a global variable is zero initialized.

> Similar argument for dive_trip_list which is a pointer variable at global
> scope, so I assume also guaranteed to be initialised to zero.

Yes. But there was a bug there that I just fixed (pushed out to Qt
branch, but the same is needed in master as well)

/D


More information about the subsurface mailing list