[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PATCH 8/8] mig/server.c (WriteVarDecls): quiet GCC warning about set bu
From: |
Marin Ramesa |
Subject: |
[PATCH 8/8] mig/server.c (WriteVarDecls): quiet GCC warning about set but unused variable |
Date: |
Wed, 11 Dec 2013 17:30:47 +0100 |
This is again that code where variable is assigned to itself, but
I don't know how to fix this the other way.
* server.c (WriteVarDecls) (msgh_simple): Assign to itself.
---
server.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/server.c b/server.c
index 8496da7..793b9fc 100644
--- a/server.c
+++ b/server.c
@@ -296,11 +296,11 @@ WriteVarDecls(FILE *file, const routine_t *rt)
fprintf(file, "\n");
if (!rt->rtSimpleFixedReply)
- fprintf(file, "\tboolean_t msgh_simple;\n");
+ fprintf(file, "\tboolean_t msgh_simple = msgh_simple;\n");
else if (!rt->rtSimpleCheckRequest)
{
fprintf(file, "#if\tTypeCheck\n");
- fprintf(file, "\tboolean_t msgh_simple;\n");
+ fprintf(file, "\tboolean_t msgh_simple = msgh_simple;\n");
fprintf(file, "#endif\t/* TypeCheck */\n");
fprintf(file, "\n");
}
--
1.8.1.4
- Re: [PATCH 4/8] Quiet GCC warnings about set but unused variables, (continued)
[PATCH 3/8] Cleanup of the copyin() and copyout() calls, Marin Ramesa, 2013/12/11
[PATCH 5/8] include/mach/mach4.defs (memory_object_create_proxy): fix passing from incompatible pointer type, Marin Ramesa, 2013/12/11
[PATCH 6/8] vm/vm_kern.c (kmem_submap): remove unnecessary cast, Marin Ramesa, 2013/12/11
[PATCH 7/8] vm/vm_resident.c (vm_page_print): remove unnecessary casts, Marin Ramesa, 2013/12/11
[PATCH 8/8] mig/server.c (WriteVarDecls): quiet GCC warning about set but unused variable,
Marin Ramesa <=