Remove unused but set variables
Discovered by unused-but-set-variable diagnostics.
Test: build
Bug: 197240255
Change-Id: I32a1185f9714848c91860fbaa76521d490c842b9
diff --git a/tools/aapt/ResourceTable.cpp b/tools/aapt/ResourceTable.cpp
index 257e96b..b9de11b 100644
--- a/tools/aapt/ResourceTable.cpp
+++ b/tools/aapt/ResourceTable.cpp
@@ -2475,11 +2475,10 @@
{
if (accessorCookie != NULL && fmt != NULL) {
AccessorCookie* ac = (AccessorCookie*)accessorCookie;
- int retval=0;
char buf[1024];
va_list ap;
va_start(ap, fmt);
- retval = vsnprintf(buf, sizeof(buf), fmt, ap);
+ vsnprintf(buf, sizeof(buf), fmt, ap);
va_end(ap);
ac->sourcePos.error("Error: %s (at '%s' with value '%s').\n",
buf, ac->attr.string(), ac->value.string());