[taskjuggler-devel] uninitialised variable

From: Nikolay Sturm (sturm_at_openbsd.org)
Date: Sat Apr 29 2006 - 18:59:14 CEST


From: Nikolay Sturm <sturm@openbsd.org>
Message-ID: <1a4f.44539b62@www.taskjuggler.org>
Date: Sat, 29 Apr 2006 18:59:14 +0200 (CEST)
Subject: [taskjuggler-devel] uninitialised variable


Hi,

not sure this is the right way to provide patches, but here it is.

The variable completionDegree is not initialised in
TaskScenario.cpp which results in build failure and probably
general unusability if the operating system happens to initialise
memory areas with junk values (as is the case on OpenBSD when
running with malloc flags).

This diff fixes it.

--- TaskScenario.cpp.orig Sat Apr 29 08:42:59 2006
+++ TaskScenario.cpp Sat Apr 29 09:00:05 2006
@@ -33,6 +33,7 @@
     endCredit = -1.0;
     reportedCompletion = -1.0;
     containerCompletion = -1.0;
+ completionDegree = 0.0;
     scheduled = FALSE;
     criticalness = pathCriticalness = 0.0;
 }

Nikolay

-- 
To unsubscribe, email: taskjuggler-devel-unsubscribe@suse.com
For additional commands, email: taskjuggler-devel-help@suse.com


This archive was generated by hypermail 2.1.7 : Sat Apr 29 2006 - 18:59:17 CEST