// Must be called BEFORE ReadWaypoints()!! void InitVirtualWaypoints() // 091102 { #if TESTBENCH StartupStore(_T(". InitVirtualWaypoints: start%s"),NEWLINE); #endif LockTaskData(); if (!AllocateWaypointList()) { StartupStore(_T("!!!!!! InitVirtualWaypoints: AllocateWaypointList FAILED. CRITIC!%s"),NEWLINE); UnlockTaskData(); // BUGFIX 091122 return; } // if first load, reserve space if (NumberOfWayPoints<=NUMRESWP) { AddReservedWaypoints(); NumberOfWayPoints=NUMRESWP; #if TESTBENCH StartupStore(_T(". InitVirtualWaypoints: done (%d vwp)%s"),NUMRESWP,NEWLINE); #endif } else { #if TESTBENCH StartupStore(_T(".. InitVirtualWaypoints: already done, skipping.%s"),NEWLINE); #endif } UnlockTaskData(); }
/** * Must be called BEFORE ReadWaypoints()!! * #LockTaskData() Needed for call this. */ void InitVirtualWaypoints() // 091102 { #if TESTBENCH StartupStore(_T(". InitVirtualWaypoints: start%s"),NEWLINE); #endif // if first load, reserve space if (WayPointList.size()<=NUMRESWP) { AddReservedWaypoints(); #if TESTBENCH StartupStore(_T(". InitVirtualWaypoints: done (%d vwp)%s"),NUMRESWP,NEWLINE); #endif } else { #if TESTBENCH StartupStore(_T(".. InitVirtualWaypoints: already done, skipping.%s"),NEWLINE); #endif } }