[Devel] [PATCH] user-cr: fix uninitialized use in shmem test

Nathan Lynch ntl at pobox.com
Tue Nov 17 16:04:27 PST 2009


With ckpt-v19-rc1 branch in user-cr I get:

shmem.c: In function ‘main’:
shmem.c:53: warning: ‘a’ may be used uninitialized in this function

Signed-off-by: Nathan Lynch <ntl at pobox.com>
---
 test/shmem.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/test/shmem.c b/test/shmem.c
index d892a25..6d7dd8a 100644
--- a/test/shmem.c
+++ b/test/shmem.c
@@ -11,7 +11,7 @@ int main(int argc, char *argv[])
 {
 	FILE *file;
 	int *addr;
-	float a;
+	float a = 0;
 	pid_t pid;
 	int pipefd[2];
 	int i, ret;
-- 
1.6.2.5



_______________________________________________
Containers mailing list
Containers at lists.linux-foundation.org
https://lists.linux-foundation.org/mailman/listinfo/containers




More information about the Devel mailing list